mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
added documentation and examples
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@149108 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
f3c80503e6
commit
ee2ede4810
3 changed files with 139 additions and 14 deletions
|
@ -1,11 +1,10 @@
|
|||
<?xml version='1.0' encoding='iso-8859-1'?>
|
||||
<!-- $Revision: 1.4 $ -->
|
||||
<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. -->
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<refentry id="function.tidy-get-body">
|
||||
<refnamediv>
|
||||
<refname>tidy_get_body</refname>
|
||||
<refpurpose>
|
||||
Returns a TidyNode Object starting from the >BODY< tag of the tidy parse tree
|
||||
Returns a TidyNode Object starting from the <body> tag of the tidy parse tree
|
||||
</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
|
@ -14,9 +13,50 @@
|
|||
<type>object</type><methodname>tidy_get_body</methodname>
|
||||
<methodparam><type>resource</type><parameter>tidy</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
This function returns a TidyNode object starting from the <body>
|
||||
tag of the tidy parse tree.
|
||||
</para>
|
||||
<para>
|
||||
<example>
|
||||
<title><function>tidy_get_body</function> example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
$html = '
|
||||
<html>
|
||||
<head>
|
||||
<title>test</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>paragraph</p>
|
||||
</body>
|
||||
</html>';
|
||||
|
||||
&warn.undocumented.func;
|
||||
$tidy = tidy_parse_string($html);
|
||||
|
||||
$body = tidy_get_body($tidy);
|
||||
echo $body->value;
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
The above example will output:
|
||||
</para>
|
||||
<screen>
|
||||
<![CDATA[
|
||||
<body>
|
||||
<p>paragraph</p>
|
||||
</body>
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</para>
|
||||
¬e.tidy.ze2;
|
||||
<para>
|
||||
See also <function>tidy_get_head</function> and
|
||||
<function>tidy_get_html</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
|
|
@ -1,22 +1,62 @@
|
|||
<?xml version='1.0' encoding='iso-8859-1'?>
|
||||
<!-- $Revision: 1.4 $ -->
|
||||
<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. -->
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<refentry id="function.tidy-get-head">
|
||||
<refnamediv>
|
||||
<refname>tidy_get_head</refname>
|
||||
<refpurpose>
|
||||
Returns a TidyNode Object starting from the >HEAD< tag of the tidy parse tree
|
||||
Returns a TidyNode Object starting from the <head> tag of the tidy parse tree
|
||||
</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
<methodsynopsis>
|
||||
<type>object</type><methodname>tidy_get_head</methodname>
|
||||
<void/>
|
||||
<methodparam><type>resource</type><parameter>tidy</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
This function returns a TidyNode object starting from the <head>
|
||||
tag of the tidy parse tree.
|
||||
</para>
|
||||
<para>
|
||||
<example>
|
||||
<title><function>tidy_get_head</function> example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
$html = '
|
||||
<html>
|
||||
<head>
|
||||
<title>test</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>paragraph</p>
|
||||
</body>
|
||||
</html>';
|
||||
|
||||
&warn.undocumented.func;
|
||||
$tidy = tidy_parse_string($html);
|
||||
|
||||
$head = tidy_get_head($tidy);
|
||||
echo $head->value;
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
The above example will output:
|
||||
</para>
|
||||
<screen>
|
||||
<![CDATA[
|
||||
<head>
|
||||
<title>test</title>
|
||||
</head>
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</para>
|
||||
¬e.tidy.ze2;
|
||||
<para>
|
||||
See also <function>tidy_get_body</function> and
|
||||
<function>tidy_get_html</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
|
|
@ -1,22 +1,67 @@
|
|||
<?xml version='1.0' encoding='iso-8859-1'?>
|
||||
<!-- $Revision: 1.5 $ -->
|
||||
<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. -->
|
||||
<!-- $Revision: 1.6 $ -->
|
||||
<refentry id="function.tidy-get-html">
|
||||
<refnamediv>
|
||||
<refname>tidy_get_html</refname>
|
||||
<refpurpose>
|
||||
Returns a TidyNode Object starting from the >HTML< tag of the tidy parse tree
|
||||
Returns a TidyNode Object starting from the <html> tag of the tidy parse tree
|
||||
</refpurpose>
|
||||
</refnamediv>
|
||||
<refsect1>
|
||||
<title>Description</title>
|
||||
<methodsynopsis>
|
||||
<type>object</type><methodname>tidy_get_html</methodname>
|
||||
<void/>
|
||||
<methodparam><type>resource</type><parameter>tidy</parameter></methodparam>
|
||||
</methodsynopsis>
|
||||
<para>
|
||||
This function returns a TidyNode object starting from the <html>
|
||||
tag of the tidy parse tree.
|
||||
</para>
|
||||
<para>
|
||||
<example>
|
||||
<title><function>tidy_get_html</function> example</title>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
$html = '
|
||||
<html>
|
||||
<head>
|
||||
<title>test</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>paragraph</p>
|
||||
</body>
|
||||
</html>';
|
||||
|
||||
&warn.undocumented.func;
|
||||
$tidy = tidy_parse_string($html);
|
||||
|
||||
$html = tidy_get_html($tidy);
|
||||
echo $html->value;
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
<para>
|
||||
The above example will output:
|
||||
</para>
|
||||
<screen>
|
||||
<![CDATA[
|
||||
<html>
|
||||
<head>
|
||||
<title>test</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>paragraph</p>
|
||||
</body>
|
||||
</html>
|
||||
]]>
|
||||
</screen>
|
||||
</example>
|
||||
</para>
|
||||
¬e.tidy.ze2;
|
||||
<para>
|
||||
See also <function>tidy_get_body</function> and
|
||||
<function>tidy_get_head</function>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
||||
|
|
Loading…
Reference in a new issue