The xml_parser_create_ns() function creates an XML parser with namespace support.
PHP xml_parser_create_ns() Function has the following syntax.
xml_parser_create_ns(encoding,separator)
Parameter | Is Required | Description |
---|---|---|
encoding | Optional. | Output encoding. Default in PHP 5.0.2 and newer is UTF-8 |
separator | Optional. | Output separator for tag name and namespace. Default is " : " |
Possible values:
This function returns a resource handle to be used by other XML functions on success, or FALSE on failure.
Create an XML parser with namespace support
<?php
$xmlparser = xml_parser_create_ns();
xml_parser_free($xmlparser);
?>