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.
(PHP 4, PHP 5, PHP 7, PHP 8)
xml_get_current_byte_index — XML パーサのカレントのバイトインデックスを得る
parser
バイトインデックスを得る XML パーサへのリファレンス。
この関数は、parser
が有効なパーサを参照しない場合に
false
、そうでない場合に
データバッファにおいてパーサが現在処理中のバイトインデックス
(先頭が 0) を返します。
バージョン | 説明 |
---|---|
8.0.0 |
引数 parser は、
XMLParser インスタンスを期待するようになりました。
これより前のバージョンでは、リソースが期待されていました。
|
この関数は、UTF-8 エンコードされたテキストに基づいたバイトインデックスを返します。 入力が他のエンコーディングであっても無視します。
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.