PHP xml_set_start_namespace_decl_handler() Function

❮ PHP XML Parser Reference


Definition and Usage

The xml_set_start_namespace_decl_handler() function sets up the start namespace declaration handler.

This function specifies what function to be called when a namespace is declared.

Note: The handler parameter can also be an array containing an object reference and a method name.

Syntax

xml_set_start_namespace_decl_handler(parser, handler)

Parameter Values

Parameter Description
parser Required. Specifies the XML parser to use
handler Required. Specifies a function to be used as an event handler. The function must have three parameters:
  • $parser - A variable containing the XML parser calling the handler
  • $prefix - A variable containing a reference to the namespace within an XML object
  • $uri - The URI of the namspace

Technical Details

Return Value: TRUE on success. FALSE on failure
PHP Version: 4.0.5+

❮ PHP XML Parser Reference
Copyright 1999-2023 by Refsnes Data. All Rights Reserved.