cvs: phpdoc /en language-snippets.ent /en/reference/array/functions array-rand.xml shuffle.xml /en/reference/math/functions mt-rand.xml rand.xml
| From: | Etienne Kneuss | Date: | Sun, 10 May 2009 17:55:00 +0000 |
| Subject: | cvs: phpdoc /en language-snippets.ent /en/reference/array/functions array-rand.xml shuffle.xml /en/reference/math/functions mt-rand.xml rand.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-3999@lists.php.net to get a copy of this message | ||
colder Sun May 10 17:55:00 2009 UTC
Modified files:
/phpdoc/en language-snippets.ent
/phpdoc/en/reference/math/functions mt-rand.xml rand.xml
/phpdoc/en/reference/array/functions array-rand.xml shuffle.xml
Log:
Document #48224 and put randomseed in the changelog
http://cvs.php.net/viewvc.cgi/phpdoc/en/language-snippets.ent?r1=1.263&r2=1.264&diff_format=u
Index: phpdoc/en/language-snippets.ent
diff -u phpdoc/en/language-snippets.ent:1.263 phpdoc/en/language-snippets.ent:1.264
--- phpdoc/en/language-snippets.ent:1.263 Sat May 2 10:20:44 2009
+++ phpdoc/en/language-snippets.ent Sun May 10 17:55:00 2009
@@ -1,7 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
-<!-- $Revision: 1.263 $ -->
+<!-- $Revision: 1.264 $ -->
<!-- Keep 'em sorted -->
+<!ENTITY changelog.randomseed '<row><entry>4.2.0</entry><entry>The
random
+number generator is seeded automatically.</entry></row>'>
<!-- Notes -->
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/math/functions/mt-rand.xml?r1=1.18&r2=1.19&diff_format=u
Index: phpdoc/en/reference/math/functions/mt-rand.xml
diff -u phpdoc/en/reference/math/functions/mt-rand.xml:1.18
phpdoc/en/reference/math/functions/mt-rand.xml:1.19
--- phpdoc/en/reference/math/functions/mt-rand.xml:1.18 Fri Jan 16 15:28:43 2009
+++ phpdoc/en/reference/math/functions/mt-rand.xml Sun May 10 17:55:00 2009
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.18 $ -->
+<!-- $Revision: 1.19 $ -->
<refentry xml:id="function.mt-rand" xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>mt_rand</refname>
@@ -34,8 +34,6 @@
between 5 and 15 (inclusive), for example, use <literal>mt_rand(5,
15)</literal>.
</simpara>
- ¬e.randomseed;
-
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
@@ -67,6 +65,24 @@
and <parameter>max</parameter> (or <function>mt_getrandmax</function>,
inclusive)
</para>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <para>
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ &changelog.randomseed;
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </para>
+ </refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/math/functions/rand.xml?r1=1.22&r2=1.23&diff_format=u
Index: phpdoc/en/reference/math/functions/rand.xml
diff -u phpdoc/en/reference/math/functions/rand.xml:1.22
phpdoc/en/reference/math/functions/rand.xml:1.23
--- phpdoc/en/reference/math/functions/rand.xml:1.22 Fri Jan 16 15:28:43 2009
+++ phpdoc/en/reference/math/functions/rand.xml Sun May 10 17:55:00 2009
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.22 $ -->
+<!-- $Revision: 1.23 $ -->
<refentry xml:id="function.rand" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>rand</refname>
@@ -33,9 +33,6 @@
<function>mt_rand</function> instead.
</simpara>
</note>
-
- ¬e.randomseed;
-
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
@@ -67,6 +64,24 @@
(or 0) and <parameter>max</parameter> (or
<function>getrandmax</function>, inclusive).
</para>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <para>
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ &changelog.randomseed;
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </para>
+ </refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/array/functions/array-rand.xml?r1=1.13&r2=1.14&diff_format=u
Index: phpdoc/en/reference/array/functions/array-rand.xml
diff -u phpdoc/en/reference/array/functions/array-rand.xml:1.13
phpdoc/en/reference/array/functions/array-rand.xml:1.14
--- phpdoc/en/reference/array/functions/array-rand.xml:1.13 Fri Jan 16 16:14:24 2009
+++ phpdoc/en/reference/array/functions/array-rand.xml Sun May 10 17:55:00 2009
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.13 $ -->
+<!-- $Revision: 1.14 $ -->
<refentry xml:id="function.array-rand" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>array_rand</refname>
@@ -50,6 +50,30 @@
random keys as well as values out of the array.
</para>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <para>
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry>5.2.10</entry>
+ <entry>
+ The resulting array of keys is no longer shuffled.
+ </entry>
+ </row>
+ &changelog.randomseed;
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </para>
+ </refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
@@ -58,7 +82,6 @@
<programlisting role="php">
<![CDATA[
<?php
-srand((float) microtime() * 10000000);
$input = array("Neo", "Morpheus", "Trinity", "Cypher",
"Tank");
$rand_keys = array_rand($input, 2);
echo $input[$rand_keys[0]] . "\n";
@@ -69,10 +92,6 @@
</example>
</para>
</refsect1>
- <refsect1 role="notes">
- &reftitle.notes;
- ¬e.randomseed;
- </refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
http://cvs.php.net/viewvc.cgi/phpdoc/en/reference/array/functions/shuffle.xml?r1=1.18&r2=1.19&diff_format=u
Index: phpdoc/en/reference/array/functions/shuffle.xml
diff -u phpdoc/en/reference/array/functions/shuffle.xml:1.18
phpdoc/en/reference/array/functions/shuffle.xml:1.19
--- phpdoc/en/reference/array/functions/shuffle.xml:1.18 Fri Mar 20 20:38:30 2009
+++ phpdoc/en/reference/array/functions/shuffle.xml Sun May 10 17:55:00 2009
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.18 $ -->
+<!-- $Revision: 1.19 $ -->
<refentry xml:id="function.shuffle" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>shuffle</refname>
@@ -56,10 +56,27 @@
</example>
</para>
</refsect1>
+ <refsect1 role="changelog">
+ &reftitle.changelog;
+ <para>
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>&Version;</entry>
+ <entry>&Description;</entry>
+ </row>
+ </thead>
+ <tbody>
+ &changelog.randomseed;
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </para>
+ </refsect1>
<refsect1 role="notes">
&reftitle.notes;
¬e.no-key-association;
- ¬e.randomseed;
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;