# Field Currently the following fields are supported: - PAGE - NUMPAGES - DATE - XE - INDEX - FILENAME - REF ``` php addField($fieldType, [$properties], [$options], [$fieldText], [$fontStyle]) ``` - ``$fontStyle``. See [`Styles > Font`](../styles/font.md). See ``\PhpOffice\PhpWord\Element\Field`` for list of properties and options available for each field type. Options which are not specifically defined can be added. Those must start with a ``\``. For instance for the INDEX field, you can do the following (See `Index Field for list of available options `_ ): ``` php addText('My '); $fieldText->addText('bold index', ['bold' => true]); $fieldText->addText(' entry'); $section->addField('XE', array(), array(), $fieldText); // this actually adds the index $section->addField('INDEX', array(), array('\\e " " \\h "A" \\c "3"'), 'right click to update index'); // Adding reference to a bookmark $fieldText->addField('REF', [ 'name' => 'bookmark' ], [ 'InsertParagraphNumberRelativeContext', 'CreateHyperLink', ]); ```