mirror of
https://github.com/php/doc-it.git
synced 2026-03-24 15:42:46 +01:00
git-svn-id: https://svn.php.net/repository/phpdoc/it/trunk@314558 c90b9560-bf6c-de11-be94-00142212c4b1
79 lines
2.1 KiB
XML
79 lines
2.1 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!-- EN-Revision: n/a Maintainer: darvina Status: ready -->
|
|
<!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 -->
|
|
<refentry xml:id="function.nl2br" xmlns="http://docbook.org/ns/docbook">
|
|
<refnamediv>
|
|
<refname>nl2br</refname>
|
|
<refpurpose>
|
|
Inserisce il tag HTML di 'a capo' prima di tutti i caratteri di 'a capo' della stringa
|
|
</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Descrizione</title>
|
|
<methodsynopsis>
|
|
<type>string</type><methodname>nl2br</methodname>
|
|
<methodparam><type>string</type><parameter>string</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Restituisce la stringa <parameter>string</parameter> con '<br />' inserito
|
|
prima di tutti i newline.
|
|
</para>
|
|
<note>
|
|
<para>
|
|
A partire dal PHP 4.0.5, <function>nl2br</function> è conforme a XHTML.
|
|
Tutte le versioni precedenti alla 4.0.5 restituiscono la
|
|
<parameter>string</parameter> con '<br>' invece di '<br />' inserito prima
|
|
degli 'a capo'.
|
|
</para>
|
|
</note>
|
|
<para>
|
|
<example>
|
|
<title>Esempio di uso di <function>nl2br</function></title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
echo nl2br("foo isn't\n bar");
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
<para>
|
|
this will output :
|
|
</para>
|
|
<screen>
|
|
<![CDATA[
|
|
foo isn't<br />
|
|
bar
|
|
]]>
|
|
</screen>
|
|
</example>
|
|
</para>
|
|
<para>
|
|
Vedere anche <function>htmlspecialchars</function>,
|
|
<function>htmlentities</function>,
|
|
<function>wordwrap</function> e
|
|
<function>str_replace</function>.
|
|
</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
|
|
-->
|