JSON API - addHeaderSection
- addBarcode
- addBookmark
- addBreak
- addCaption
- addChart
- addComment
- addCrossReference
- addDateAndHour
- addDropCap
- addEndnote
- addExternalFile
- addFootnote
- addFormElement
- addHeading
- addImage
- addLink
- addList
- addMathEquation
- addMergeField
- addPageNumber
- addRuby
- addSimpleField
- addStructuredDocumentTag
- addSVG
- addTab
- addTable
- addTableContents
- addTableFigures
- addText
- addTextBox
- addWordML
- addWordFragment
- embedHTML
- addBackgroundImage
- addFooter
- addFooterSection
- addHeader
- addHeaderSection
- addLineNumbering
- addPageBorders
- addProperties
- addSection
- createCharacterStyle
- createListStyle
- createParagraphStyle
- createTableStyle
- docxSettings
- embedFont
- modifyPageLayout
- removeFooters
- removeHeaders
- setBackgroundColor
- setCompatibilityMode
- setDefaultFont
- setDocumentDefaultStyles
- setLanguage
- setMarkAsFinal
- setRTL
- clearBlocks
- cloneBlock
- deleteBlock
- getTemplateVariables
- getTemplateVariablesType
- modifyInputFields
- modifyMergeFields
- processTemplate
- removeTemplateVariable
- removeTemplateVariableImage
- replaceBlock
- replaceListVariable
- replacePlaceholderImage
- replaceTableVariable
- replaceVariableByExternalFile
- replaceVariableByHTML
- replaceVariableByText
- replaceVariableByWordFragment
- replaceVariableByWordML
- setTemplateSymbol
- setTemplateBlockSymbol
- tickCheckboxes
addHeaderSection
PREMIUM
TRIAL / ADVANCED
Inserts headers in a specific section of a Word document.
Note
You are reading the JSON API documentation. For the PHP API method please go to addHeaderSection.
The contents of the different headers are defined via the use of WordFragments.
JSON data
Styles from addText can be used.
| Key | Description |
|---|---|
| default | The WordFragment containing the contents for the default (odd pages) header. |
| even | The WordFragment containing the contents for the even pages header. |
| first | The WordFragment containing the contents for the first (title) page header. |
| section | Section position. -1 as default. 0 is the first section and -1 the last section. |
| removeOthers | If true remove other headers in the section. Default as false. |
Code samples
Example #1
Release notes
- phpdocx 18.0:
- new action.
