PHP 8.5.0 Alpha 1 available for testing

xml_get_current_byte_index

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

xml_get_current_byte_indexDevuelve el índice del byte actual de un analizador XML

Descripción

xml_get_current_byte_index(XMLParser $parser): int

Devuelve el índice del byte actual del analizador XML dado.

Parámetros

parser

Una referencia a un analizador XML válido.

Valores devueltos

xml_get_current_byte_index() devuelve el índice del byte de análisis actual del analizador XML (comienza en 0).

Historial de cambios

Versión Descripción
8.0.0 parser ahora espera una instancia de XMLParser en lugar de un resource xml.

Notas

Advertencia

Esta función devuelve el índice del byte de acuerdo con el texto codificado en UTF-8 incluso si la entrada está en otra codificación.

Ver también

add a note

User Contributed Notes 1 note

up
1
turan dot yuksel at tcmb dot gov dot tr
19 years ago
The outcome of this function is heavily dependent on the parser implementation used. For example, at the point where the start_element_ callback is called, libxml2 parser consumes the entire element name and attributes, however expat does not.
To Top