mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-19 18:38:55 +00:00

- array functions - datetime functions - mbstring functions - strings functions - var functions - xml functions - json functions
111 lines
3 KiB
XML
111 lines
3 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<refentry xml:id="function.xml-parser-create" xmlns="http://docbook.org/ns/docbook">
|
|
<refnamediv>
|
|
<refname>xml_parser_create</refname>
|
|
<refpurpose>Create an XML parser</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>XMLParser</type><methodname>xml_parser_create</methodname>
|
|
<methodparam choice="opt"><type class="union"><type>string</type><type>null</type></type><parameter>encoding</parameter><initializer>&null;</initializer></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
<function>xml_parser_create</function> creates a new XML parser
|
|
and returns a <classname>XMLParser</classname> instance to be used by the
|
|
other XML functions.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>encoding</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
The input
|
|
encoding is automatically detected, so that the
|
|
<parameter>encoding</parameter> parameter specifies only the output
|
|
encoding. If empty string is passed, the parser attempts to identify
|
|
which encoding the document is encoded in by looking at the heading 3 or
|
|
4 bytes. The default output charset is UTF-8. The supported
|
|
encodings are <literal>ISO-8859-1</literal>, <literal>UTF-8</literal> and
|
|
<literal>US-ASCII</literal>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
&reftitle.returnvalues;
|
|
<para>
|
|
Returns a new <classname>XMLParser</classname> instance.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="changelog">
|
|
&reftitle.changelog;
|
|
<informaltable>
|
|
<tgroup cols="2">
|
|
<thead>
|
|
<row>
|
|
<entry>&Version;</entry>
|
|
<entry>&Description;</entry>
|
|
</row>
|
|
</thead>
|
|
<tbody>
|
|
<row>
|
|
<entry>8.0.0</entry>
|
|
<entry>
|
|
This function returns an <classname>XMLParser</classname> instance now;
|
|
previously, a <type>resource</type> was returned, &return.falseforfailure;.
|
|
</entry>
|
|
</row>
|
|
<row>
|
|
<entry>8.0.0</entry>
|
|
<entry>
|
|
<parameter>encoding</parameter> is nullable now.
|
|
</entry>
|
|
</row>
|
|
</tbody>
|
|
</tgroup>
|
|
</informaltable>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<para>
|
|
<simplelist>
|
|
<member><function>xml_parser_create_ns</function></member>
|
|
<member><function>xml_parser_free</function></member>
|
|
</simplelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
</refentry>
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|