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.
xml_get_current_byte_index
(PHP 4, PHP 5)
xml_get_current_byte_index — Restituisce l'indice del byte corrente per un parser XML
Descrizione
int xml_get_current_byte_index
( resource
$parser
)Restituisce l'indice del byte corrente per il parser XML fornito.
Elenco dei parametri
-
parser -
Un riferimento al parser XML per ottenere l'indice del byte da esso.
Valori restituiti
Questa funzione restituisce FALSE se parser
non si riferisce ad un parser valido, o altrimenti viene restituito l'indice del byte
sul quale è correntemente il parser nel suo buffer di dati (a partire da 0).
Note
Avviso
Questa funzione restituisce l'indice del byte nella codifica testuale UTF-8 senza tener conto se l'input è in un'altra codifica.
Vedere anche:
- xml_get_current_column_number() - Restituisce il numero di colonna corrente per un parser XML
- xml_get_current_line_number() - Restituisce il numero di linea corrente per un parser XML
turan dot yuksel at tcmb dot gov dot tr ¶
7 years ago
