PHP.nl

xml_parser_set_option

xml_parser_set_option

Set options in an XML parser

bool **xml_parser_set_option** XMLParser $parser int $option  $value

Sets an option in an XML parser.

parserA reference to the XML parser to set an option in.

optionWhich option to set. See below.

The following options are available:

valueThe option's new value.

Returns true on success or false on failure.

Throws a when an invalid value is passed to . ValueError``option

Prior to PHP 8.0.0, the function returned false when passing an invalid value to generated a as well as making the function return false. option``E_WARNING