PHP 8.3.4 Released!

xml_set_notation_decl_handler

(PHP 4, PHP 5, PHP 7, PHP 8)

xml_set_notation_decl_handlerSet up notation declaration handler

Descrição

xml_set_notation_decl_handler(XMLParser $parser, callable $handler): true

Sets the notation declaration handler function for the XML parser parser.

A notation declaration is part of the document's DTD and has the following format:

<!NOTATION <parameter>name</parameter>
{ <parameter>systemId</parameter> | <parameter>publicId</parameter>?>
See » section 4.7 of the XML 1.0 spec for the definition of notation declarations.

Parâmetros

parser

O analisador XML.

handler

Se null ou uma string vazia for passada, o manipulador será redefinido para seu estado padrão.

Se handler for um callable, o callable será definido como o manipulador.

Se handler for uma string, ela pode ser o nome de um método de um objet definido com xml_set_object().

The signature of the handler must be:

handler(
    XMLParser $parser,
    string $notation_name,
    string|false $base,
    string $system_id,
    string|false $public_id
): void
parser
O analisador XML que chama o manipulador.
notation_name
This is the notation's name, as per the notation format described above.
base
This is the base for resolving the system identifier (system_id) of the notation declaration.
system_id
System identifier of the external notation declaration.
public_id
Public identifier of the external notation declaration.

Valor Retornado

Sempre retorna true.

Registro de Alterações

Versão Descrição
8.0.0 O parâmetro parser agora espera uma instância de XMLParser; anteriormente, um resource xml válido era esperado.
add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top