List styles: simpleTemplate.docx

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 1))

SAMPLE RESULT:

  • item 1
  • item 2
  • subitem 2_1
  • subitem 2_2
  • item 3
  • subitem 3_1
  • subitem 3_2
  • sub_subitem 3_2_1
  • sub_subitem 3_2_1
  • item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 2))

SAMPLE RESULT:

  1. item 1
  2. item 2
  3. subitem 2_1
  4. subitem 2_2
  5. item 3
  6. subitem 3_1
  7. subitem 3_2
  8. sub_subitem 3_2_1
  9. sub_subitem 3_2_1
  10. item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 3))

SAMPLE RESULT:

1) item 1

2) item 2

a) subitem 2_1

b) subitem 2_2

3) item 3

a) subitem 3_1

b) subitem 3_2

i) sub_subitem 3_2_1

ii) sub_subitem 3_2_1

4) item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 4))

SAMPLE RESULT:

  1. item 1
  2. item 2
  3. subitem 2_1
  4. subitem 2_2
  5. item 3
  6. subitem 3_1
  7. subitem 3_2
  8. sub_subitem 3_2_1
  9. sub_subitem 3_2_1
  10. item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 5))

SAMPLE RESULT:

 item 1

 item 2

 subitem 2_1

 subitem 2_2

 item 3

 subitem 3_1

 subitem 3_2

  • sub_subitem 3_2_1
  • sub_subitem 3_2_1

 item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 6))

SAMPLE RESULT:

Article I. item 1

Article II. item 2

Section 2.01 subitem 2_1

Section 2.02 subitem 2_2

Article III. item 3

Section 3.01 subitem 3_1

Section 3.02 subitem 3_2

(a) sub_subitem 3_2_1

(b) sub_subitem 3_2_1

Article IV. item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 7))

SAMPLE RESULT:

1 item 1

2 item 2

2.1 subitem 2_1

2.2 subitem 2_2

3 item 3

3.1 subitem 3_1

3.2 subitem 3_2

3.2.1 sub_subitem 3_2_1

3.2.2 sub_subitem 3_2_1

4 item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 65407781))

SAMPLE RESULT:

  • item 1
  • item 2
  • subitem 2_1
  • subitem 2_2
  • item 3
  • subitem 3_1
  • subitem 3_2
  • sub_subitem 3_2_1
  • sub_subitem 3_2_1
  • item 4

SAMPLE CODE:

$myList = array('item 1',
'item 2',
array('subitem 2_1',
'subitem 2_2'),
'item 3',
array('subitem 3_1',
'subitem 3_2',
array('sub_subitem 3_2_1',
'sub_subitem 3_2_1')),
'item 4');
addList($myList, 65407782))

SAMPLE RESULT:

  1. item 1
  2. item 2
  3. subitem 2_1
  4. subitem 2_2
  5. item 3
  6. subitem 3_1
  7. subitem 3_2
  8. sub_subitem 3_2_1
  9. sub_subitem 3_2_1
  10. item 4

Paragraph and Table styles: simpleTemplate.docx

NAME: / Normal
Type: / paragraph
ID: / Normal
Default: / true
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'Normal'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / Normal Table
Type: / table
ID: / TableNormal
Default: / true
Custom: / false

SAMPLE CODE:

addTable(array(array('Title A','Title B','Title C'),array('First row A','First row B','First row C'),array('Second row A','Second row B','Second row C')), array('tableStyle'=> 'TableNormal'), 'columnWidths' => array(1800, 1800, 1800))

SAMPLE RESULT:

Title A / Title B / Title C
First row A / First row B / First row C
Second row A / Second row B / Second row C
NAME: / List Paragraph PHPDOCX
Type: / paragraph
ID: / ListParagraphPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'ListParagraphPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / Title PHPDOCX
Type: / paragraph
ID: / TitlePHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'TitlePHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / Subtitle PHPDOCX
Type: / paragraph
ID: / SubtitlePHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'SubtitlePHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / Normal Table PHPDOCX
Type: / table
ID: / NormalTablePHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addTable(array(array('Title A','Title B','Title C'),array('First row A','First row B','First row C'),array('Second row A','Second row B','Second row C')), array('tableStyle'=> 'NormalTablePHPDOCX'), 'columnWidths' => array(1800, 1800, 1800))

SAMPLE RESULT:

Title A / Title B / Title C
First row A / First row B / First row C
Second row A / Second row B / Second row C
NAME: / Table Grid PHPDOCX
Type: / table
ID: / TableGridPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addTable(array(array('Title A','Title B','Title C'),array('First row A','First row B','First row C'),array('Second row A','Second row B','Second row C')), array('tableStyle'=> 'TableGridPHPDOCX'), 'columnWidths' => array(1800, 1800, 1800))

SAMPLE RESULT:

Title A / Title B / Title C
First row A / First row B / First row C
Second row A / Second row B / Second row C
NAME: / annotation text PHPDOCX
Type: / paragraph
ID: / CommentTextPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'CommentTextPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / annotation subject PHPDOCX
Type: / paragraph
ID: / CommentSubjectPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'CommentSubjectPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / Balloon Text PHPDOCX
Type: / paragraph
ID: / BalloonTextPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'BalloonTextPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / footnote Text PHPDOCX
Type: / paragraph
ID: / footnoteTextPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'footnoteTextPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test

NAME: / endnote Text PHPDOCX
Type: / paragraph
ID: / endnoteTextPHPDOCX
Default: / false
Custom: / false

SAMPLE CODE:

addText('This is some sample paragraph test', array('pStyle' => 'endnoteTextPHPDOCX'))

SAMPLE RESULT:

This is some sample paragraph test