Fixed bug#54611 one functionality is left out

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@310543 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Hannes Magnusson 2011-04-27 08:45:13 +00:00
parent 6370ba265f
commit 0cc8f380b3

View file

@ -15,7 +15,8 @@
</methodsynopsis>
<para>
Returns <parameter>string</parameter> with '&lt;br /&gt;' or
'&lt;br&gt;' inserted before all newlines.
'&lt;br&gt;' inserted before all newlines (<literal>\r\n</literal>,
<literal>\n\r</literal>, <literal>\n</literal> and <literal>\r</literal>).
</para>
</refsect1>
@ -54,7 +55,7 @@
&reftitle.examples;
<para>
<example>
<title>using <function>nl2br</function></title>
<title>Using <function>nl2br</function></title>
<programlisting role="php">
<![CDATA[
<?php
@ -84,6 +85,26 @@ echo nl2br("Welcome\r\nThis is my HTML document", false);
<![CDATA[
Welcome<br>
This is my HTML document
]]>
</screen>
</example>
<example>
<title>Various newline seperators</title>
<programlisting role="php">
<![CDATA[
<?php
$string = "This\r\nis\n\ra\nstring\r";
echo nl2br($string);
?>
]]>
</programlisting>
&example.outputs;
<screen>
<![CDATA[
This<br />
is<br />
a<br />
string<br />
]]>
</screen>
</example>