nlopess Tue Mar 9 14:33:06 2004 EDT
Modified files: /phpdoc/en/reference/tidy/functions tidy-get-output.xml tidy-get-status.xml Log: more tidy docs and examples #can somebody check my english in tidy_get_status please? http://cvs.php.net/diff.php/phpdoc/en/reference/tidy/functions/tidy-get-output.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc/en/reference/tidy/functions/tidy-get-output.xml diff -u phpdoc/en/reference/tidy/functions/tidy-get-output.xml:1.1 phpdoc/en/reference/tidy/functions/tidy-get-output.xml:1.2 --- phpdoc/en/reference/tidy/functions/tidy-get-output.xml:1.1 Tue Nov 4 08:26:55 2003 +++ phpdoc/en/reference/tidy/functions/tidy-get-output.xml Tue Mar 9 14:33:06 2004 @@ -1,6 +1,5 @@ <?xml version='1.0' encoding='iso-8859-1'?> -<!-- $Revision: 1.1 $ --> -<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. --> +<!-- $Revision: 1.2 $ --> <refentry id="function.tidy-get-output"> <refnamediv> <refname>tidy_get_output</refname> @@ -12,11 +11,46 @@ <title>Description</title> <methodsynopsis> <type>string</type><methodname>tidy_get_output</methodname> - <void/> + <methodparam><type>resource</type><parameter>tidy</parameter></methodparam> </methodsynopsis> + <para> + <function>tidy_get_output</function> returns a string with the repaired + html. + </para> + <para> + <example> + <title><function>tidy_get_output</function> example</title> + <programlisting role="php"> +<![CDATA[ +<?php - &warn.undocumented.func; +$html = '<p>paragraph</i>'; +$tidy = tidy_parse_string($html); +$tidy->CleanRepair(); + +echo tidy_get_output($tidy); +?> +]]> + </programlisting> + <para> + The above example will output: + </para> + <screen> +<![CDATA[ +<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN"> +<html> +<head> +<title></title> +</head> +<body> +<p>paragraph</p> +</body> +</html> +]]> + </screen> + </example> + </para> </refsect1> </refentry> http://cvs.php.net/diff.php/phpdoc/en/reference/tidy/functions/tidy-get-status.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc/en/reference/tidy/functions/tidy-get-status.xml diff -u phpdoc/en/reference/tidy/functions/tidy-get-status.xml:1.2 phpdoc/en/reference/tidy/functions/tidy-get-status.xml:1.3 --- phpdoc/en/reference/tidy/functions/tidy-get-status.xml:1.2 Fri Dec 19 10:49:59 2003 +++ phpdoc/en/reference/tidy/functions/tidy-get-status.xml Tue Mar 9 14:33:06 2004 @@ -1,6 +1,5 @@ <?xml version='1.0' encoding='iso-8859-1'?> -<!-- $Revision: 1.2 $ --> -<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. --> +<!-- $Revision: 1.3 $ --> <refentry id="function.tidy-get-status"> <refnamediv> <refname>tidy_get_status</refname> @@ -12,11 +11,33 @@ <title>Description</title> <methodsynopsis> <type>int</type><methodname>tidy_get_status</methodname> - <void/> + <methodparam><type>resource</type><parameter>tidy</parameter></methodparam> </methodsynopsis> + <para> + <function>tidy_get_status</function> returns the status for the specified + <parameter>tidy</parameter> resource. It returns 0 if no error/warning + was raised, 1 for warnings or accessibilities errors, and 2 for errors. + </para> + <para> + <example> + <title><function>tidy_get_status</function> example</title> + <programlisting role="php"> +<![CDATA[ +<?php +$html = '<p>paragraph</i>'; +$tidy = tidy_parse_string($html); - &warn.undocumented.func; +$html2 = '<bogus>test</bogus>'; +$tidy2 = tidy_parse_string($html2); +echo tidy_get_status($tidy); //1 + +echo tidy_get_status($tidy2); //2 +?> +]]> + </programlisting> + </example> + </para> </refsect1> </refentry>