cvs: phpdoc-it /reference/strings/functions number-format.xml parse-str.xml printf.xml quoted-printable-decode.xml quotemeta.xml rtrim.xml
setlocale.xml similar-text.xml sprintf.xml

From: Date: Tue, 10 May 2005 12:38:58 +0000
Subject: cvs: phpdoc-it /reference/strings/functions number-format.xml parse-str.xml printf.xml quoted-printable-decode.xml quotemeta.xml rtrim.xml
setlocale.xml similar-text.xml sprintf.xml
Groups: php.doc.it 
Request: Send a blank email to doc-it+get-713@lists.php.net to get a copy of this message
darvina Tue May 10 08:38:58 2005 EDT Modified files: /phpdoc-it/reference/strings/functions number-format.xml parse-str.xml printf.xml quoted-printable-decode.xml quotemeta.xml rtrim.xml setlocale.xml similar-text.xml sprintf.xml Log: Sync to En tree

http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/number-format.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc-it/reference/strings/functions/number-format.xml diff -u phpdoc-it/reference/strings/functions/number-format.xml:1.2 phpdoc-it/reference/strings/functions/number-format.xml:1.3 --- phpdoc-it/reference/strings/functions/number-format.xml:1.2 Thu Sep 16 08:20:38 2004 +++ phpdoc-it/reference/strings/functions/number-format.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.5 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.6 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/math.xml, last change in rev 1.2 --> <refentry id="function.number-format"> <refnamediv> @@ -12,12 +12,7 @@ <type>string</type><methodname>number_format</methodname> <methodparam><type>float</type><parameter>number</parameter></methodparam> <methodparam choice="opt"><type>int</type><parameter>decimals</parameter></methodparam> - </methodsynopsis> - <methodsynopsis> - <type>string</type><methodname>number_format</methodname> - <methodparam><type>float</type><parameter>number</parameter></methodparam> - <methodparam><type>int</type><parameter>decimals</parameter></methodparam> - <methodparam><type>string</type><parameter>dec_point</parameter></methodparam> + <methodparam choice="opt"><type>string</type><parameter>dec_point</parameter></methodparam> <methodparam><type>string</type><parameter>thousands_sep</parameter></methodparam> </methodsynopsis> <para> http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/parse-str.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc-it/reference/strings/functions/parse-str.xml diff -u phpdoc-it/reference/strings/functions/parse-str.xml:1.1 phpdoc-it/reference/strings/functions/parse-str.xml:1.2 --- phpdoc-it/reference/strings/functions/parse-str.xml:1.1 Mon Aug 9 08:01:48 2004 +++ phpdoc-it/reference/strings/functions/parse-str.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.5 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.10 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.parse-str"> <refnamediv> @@ -11,8 +11,7 @@ <methodsynopsis> <type>void</type><methodname>parse_str</methodname> <methodparam><type>string</type><parameter>str</parameter></methodparam> - <methodparam choice="opt"><type>array</type><parameter>arr - </parameter></methodparam> + <methodparam choice="opt"><type>array</type><parameter>arr</parameter></methodparam> </methodsynopsis> <para> Suddivide la stringa <parameter>str</parameter> come se fosse una stringa di query @@ -33,6 +32,14 @@ <link linkend="language.variables.external">variabili esterne al PHP</link>. </para> </note> + <note> + <para> + L'impostazione <link linkend="ini.magic-quotes-gpc">magic_quotes_gpc</link> + influisce sull'output di questa funzione, poichè <function>parse_str</function> utilizza + lo stesso meccanismo che usa il PHP per compilare le variabili + <literal>$_GET</literal>, <literal>$_POST</literal>, ecc. + </para> + </note> <para> <example> <title>Esempio di uso di <function>parse_str</function></title> @@ -57,7 +64,7 @@ </para> <para> Vedere anche <function>parse_url</function>, <function>pathinfo</function>, - <function>set_magic_quotes_runtime</function> e <function>urldecode</function>. + <function>get_magic_quotes_gpc</function> e <function>urldecode</function>. </para> </refsect1> </refentry> http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/printf.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc-it/reference/strings/functions/printf.xml diff -u phpdoc-it/reference/strings/functions/printf.xml:1.1 phpdoc-it/reference/strings/functions/printf.xml:1.2 --- phpdoc-it/reference/strings/functions/printf.xml:1.1 Mon Aug 9 08:01:48 2004 +++ phpdoc-it/reference/strings/functions/printf.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.6 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.7 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.printf"> <refnamediv> @@ -12,6 +12,7 @@ <type>int</type><methodname>printf</methodname> <methodparam><type>string</type><parameter>format</parameter></methodparam> <methodparam choice="opt"><type>mixed</type><parameter>args</parameter></methodparam> + <methodparam choice="opt"><type>mixed</type><parameter>...</parameter></methodparam> </methodsynopsis> <simpara> Produce un output formattato secondo le specifiche del parametro <parameter>format</parameter>, che http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/quoted-printable-decode.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc-it/reference/strings/functions/quoted-printable-decode.xml diff -u phpdoc-it/reference/strings/functions/quoted-printable-decode.xml:1.2 phpdoc-it/reference/strings/functions/quoted-printable-decode.xml:1.3 --- phpdoc-it/reference/strings/functions/quoted-printable-decode.xml:1.2 Thu Sep 16 08:20:38 2004 +++ phpdoc-it/reference/strings/functions/quoted-printable-decode.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.2 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.3 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.quoted-printable-decode"> <refnamediv> @@ -16,7 +16,10 @@ </methodsynopsis> <simpara> Questa funzione restituisce una stringa a 8 bit corrispondente alla codifica - della stringa 'quoted-printable'. Questa funzione è simile a + della stringa 'quoted-printable' ( in base a + <ulink url="&url.rfc;2045">RFC2045</ulink>, sezione 6.7, e non + <ulink url="&url.rfc;2821">RFC2821</ulink>, sezione 4.5.2, punti + addizionali non sono rimossi dall'inizio della linea). Questa funzione è simile a <function>imap_qprint</function>, tranne che quest'ultima richiede il modulo IMAP per essere utilizzata. </simpara> http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/quotemeta.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc-it/reference/strings/functions/quotemeta.xml diff -u phpdoc-it/reference/strings/functions/quotemeta.xml:1.1 phpdoc-it/reference/strings/functions/quotemeta.xml:1.2 --- phpdoc-it/reference/strings/functions/quotemeta.xml:1.1 Mon Aug 9 08:01:48 2004 +++ phpdoc-it/reference/strings/functions/quotemeta.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.3 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.4 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.139 --> <refentry id="function.quotemeta"> <refnamediv> @@ -15,7 +15,7 @@ <para> Restituisce una versione di <parameter>str</parameter> con il carattere backslash (<literal>\</literal>) davanti ai seguenti - caratteri: <screen>. \\ + * ? [ ^ ] ( $ )</screen> + caratteri: <screen>. \ + * ? [ ^ ] ( $ )</screen> </para> &note.bin-safe; http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/rtrim.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc-it/reference/strings/functions/rtrim.xml diff -u phpdoc-it/reference/strings/functions/rtrim.xml:1.2 phpdoc-it/reference/strings/functions/rtrim.xml:1.3 --- phpdoc-it/reference/strings/functions/rtrim.xml:1.2 Thu Sep 16 08:20:38 2004 +++ phpdoc-it/reference/strings/functions/rtrim.xml Tue May 10 08:38:58 2005 @@ -1,11 +1,11 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.4 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.6 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.31 --> <refentry id="function.rtrim"> <refnamediv> <refname>rtrim</refname> <refpurpose> - Rimuove gli spazi dalla fine della stringa + Rimuove gli spazi (ed altri caratteri) dalla fine della stringa </refpurpose> </refnamediv> <refsect1> @@ -73,8 +73,7 @@ </para> <example> <title>Esempio di uso di <function>rtrim</function></title> - <para> - <programlisting role="php"> + <programlisting role="php"> <![CDATA[ <?php @@ -89,8 +88,7 @@ ?> ]]> - </programlisting> - </para> + </programlisting> </example> <para> Vedere anche <function>trim</function> e <function>ltrim</function>. http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/setlocale.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc-it/reference/strings/functions/setlocale.xml diff -u phpdoc-it/reference/strings/functions/setlocale.xml:1.2 phpdoc-it/reference/strings/functions/setlocale.xml:1.3 --- phpdoc-it/reference/strings/functions/setlocale.xml:1.2 Thu Sep 16 08:20:39 2004 +++ phpdoc-it/reference/strings/functions/setlocale.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.20 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.22 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.setlocale"> <refnamediv> @@ -67,13 +67,13 @@ </simpara> </note> <para> - Se il parametro <parameter>locale</parameter> è una stringa vuota + Se il parametro <parameter>locale</parameter> è &null; oppure una stringa vuota <literal>""</literal>, i nomi locali saranno impostati dai valori delle omonime variabili d'ambiente, oppure da "LANG". </para> <para> - Se il parametro <parameter>locale</parameter> è &null; oppure <literal>"0"</literal>, + Se il parametro <parameter>locale</parameter> vale <literal>"0"</literal>, le impostazioni localizzate non vengono toccate, ma vengono restituiti i valori correnti. </para> <para> @@ -95,6 +95,7 @@ Un nome di categoria non valido genera anche un warning. I nomi delle categoria possono essere trovati nella <ulink url="&url.rfc;1766">RFC 1766</ulink> e <ulink url="&url.iso-639;">ISO 639</ulink>. + Differenti sistemi hanno differenti schemi di denominazione delle impostazioni locali. </para> <note> <para> http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/similar-text.xml?r1=1.1&r2=1.2&ty=u Index: phpdoc-it/reference/strings/functions/similar-text.xml diff -u phpdoc-it/reference/strings/functions/similar-text.xml:1.1 phpdoc-it/reference/strings/functions/similar-text.xml:1.2 --- phpdoc-it/reference/strings/functions/similar-text.xml:1.1 Mon Aug 9 08:01:48 2004 +++ phpdoc-it/reference/strings/functions/similar-text.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.5 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.6 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.similar-text"> <refnamediv> @@ -14,7 +14,7 @@ <type>int</type><methodname>similar_text</methodname> <methodparam><type>string</type><parameter>first</parameter></methodparam> <methodparam><type>string</type><parameter>second</parameter></methodparam> - <methodparam choice="opt"><type>float</type><parameter>&amp;percent</parameter></methodparam> + <methodparam choice="opt"><type>float</type><parameter role="reference">percent</parameter></methodparam> </methodsynopsis> <para> Questa funzione calcola la similitudine tra due stringhe come descritto http://cvs.php.net/diff.php/phpdoc-it/reference/strings/functions/sprintf.xml?r1=1.2&r2=1.3&ty=u Index: phpdoc-it/reference/strings/functions/sprintf.xml diff -u phpdoc-it/reference/strings/functions/sprintf.xml:1.2 phpdoc-it/reference/strings/functions/sprintf.xml:1.3 --- phpdoc-it/reference/strings/functions/sprintf.xml:1.2 Thu Sep 16 08:20:39 2004 +++ phpdoc-it/reference/strings/functions/sprintf.xml Tue May 10 08:38:58 2005 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- EN-Revision: 1.10 Maintainer: darvina Status: ready --> +<!-- EN-Revision: 1.15 Maintainer: darvina Status: ready --> <!-- splitted from ./en/functions/strings.xml, last change in rev 1.2 --> <refentry id="function.sprintf"> <refnamediv> @@ -12,6 +12,7 @@ <type>string</type><methodname>sprintf</methodname> <methodparam><type>string</type><parameter>format</parameter></methodparam> <methodparam choice="opt"><type>mixed</type><parameter>args</parameter></methodparam> + <methodparam choice="opt"><type>mixed</type><parameter>...</parameter></methodparam> </methodsynopsis> <simpara> La funzione restituisce una stringa formattata in base al parametro @@ -32,6 +33,14 @@ <orderedlist> <listitem> <simpara> + Un parametro opzionale di <emphasis>specifica del segno</emphasis> che forza la presenza del segno + (- oppure +) in caso di numero. Per default, si usa soltanto il segno - + se il numero è negativo. Questo parametro forza i numeri positiva ad avere + il segno +, ed è stato aggiunto in PHP 4.3.0. + </simpara> + </listitem> + <listitem> + <simpara> Un parametro opzionale per la specifica del <emphasis>riempimento</emphasis> che indica quale carattere sarà utilizzato per completare la stringa risultante in modo da raggiungere la dimensione richiesta. Questo può essere uno spazio oppure uno @@ -96,7 +105,12 @@ </member> <member> <literal>f</literal> - l'argomento è trattato come un - <type>float</type> e sarà presentato come un numero in virgola mobile. + <type>float</type> e sarà presentato come un numero in virgola mobile (influenzato dalle impostazioni locali). + </member> + <member> + <literal>F</literal> - l'argomento è trattato come un numero + float, e sarà presentato come un numero in virgola mobile (non influenzato dalle impostazioni locali). + Disponibile da PHP 4.3.10 e PHP 5.0.3. </member> <member> <literal>o</literal> - l'argomento è trattato come un @@ -211,6 +225,8 @@ printf("%%s = '%s'\n", $n); // stringa printf("%%x = '%x'\n", $n); // rappresentazione esadecimale (minuscolo) printf("%%X = '%X'\n", $n); // rappresentazione esadecimale (maiuscolo) +printf("%%+d = '%+d'\n", $n); // indicazione del segno su un intero positivo +printf("%%+d = '%+d'\n", $u); // indicazione del segno su un intero negativo ?> ]]> </programlisting> @@ -230,6 +246,8 @@ %s = '43951789' %x = '29ea6ad' %X = '29EA6AD' +%+d = '+43951789' +%+d = '-43951789' ]]> </screen> </example> @@ -245,6 +263,7 @@ printf("[%10s]\n", $s); // accostamento a destra con spazi printf("[%-10s]\n", $s); // accostamento a sinistra con spazi printf("[%010s]\n", $s); // completamento con zero funziona anche con le stringhe +printf("[%'#10s]\n", $s); // utilizza il carattere di riempimento '#' printf("[%10.10s]\n", $t); // accostamento a sinistra con taglio a 10 caratteri ?> ]]> @@ -258,6 +277,7 @@ [ monkey] [monkey ] [0000monkey] +[####monkey] [many monke] ]]> </screen>
« previous php.doc.it (#713) next »