XMLWriter

はじめに

これは、XMLWriter 拡張モジュールです。 libxml の xmlWriter API をラップしています。

この拡張モジュールは、キャッシュ処理をしない前進のみのライターで、 XML データを含むストリームあるいはファイルを作成します。

この拡張モジュールは、オブジェクト指向形式と手続き型のどちらでも使用可能です。 全メソッドについて、その両方のコール方法を説明しています。

add a note

User Contributed Notes 2 notes

up
5
Alexey Zakhlestin
17 years ago
important: XMLWriter expects UTF-8 data from you. It can output xml in various encodings, but input should be strictly utf-8!
up
-3
lingtalfi
10 years ago
The single quote predefined entity is not escaped.
The other predefined entities are but not the single quote, so you will have to do it yourself.

That's what you would expect:

Ampersand     &     &
Single Quote     '     '
Double Quote     "     "
Greater Than     >     >
Less Than     <     &lt;

That's what you get with \XmlWriter:

Ampersand     &     &amp;
Single Quote     '     '
Double Quote     "     &quot;
Greater Than     >     &gt;
Less Than     <     &lt;
To Top