mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 08:58:56 +00:00
uniqid: fix return type, use lcg parameter in example
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@65771 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
a4b7e945cd
commit
10e9116e33
1 changed files with 5 additions and 5 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.63 $ -->
|
||||
<!-- $Revision: 1.64 $ -->
|
||||
<reference id="ref.misc">
|
||||
<title>Miscellaneous functions</title>
|
||||
<titleabbrev>Misc.</titleabbrev>
|
||||
|
@ -941,7 +941,7 @@ $binarydata = pack ("nvc*", 0x1234, 0x5678, 65, 66);
|
|||
<title>Description</title>
|
||||
<funcsynopsis>
|
||||
<funcprototype>
|
||||
<funcdef>int <function>uniqid</function></funcdef>
|
||||
<funcdef>string <function>uniqid</function></funcdef>
|
||||
<paramdef>string <parameter>prefix</parameter></paramdef>
|
||||
<paramdef>bool
|
||||
<parameter><optional>lcg</optional></parameter>
|
||||
|
@ -953,7 +953,7 @@ $binarydata = pack ("nvc*", 0x1234, 0x5678, 65, 66);
|
|||
based on the current time in microseconds. The prefix can be
|
||||
useful for instance if you generate identifiers simultaneously on
|
||||
several hosts that might happen to generate the identifier at the
|
||||
same microsecond. <parameter>Prefix</parameter> can be up to 114
|
||||
same microsecond. <parameter>Prefix</parameter> can be up to 114
|
||||
characters long.
|
||||
</simpara>
|
||||
<simpara>
|
||||
|
@ -980,8 +980,8 @@ $binarydata = pack ("nvc*", 0x1234, 0x5678, 65, 66);
|
|||
<informalexample>
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
$token = md5 (uniqid ("")); // no random portion
|
||||
$better_token = md5 (uniqid (rand())); // better, difficult to guess
|
||||
$token = md5(uniqid("")); // no prefix
|
||||
$better_token = md5(uniqid(rand(),1)); // better, difficult to guess
|
||||
]]>
|
||||
</programlisting>
|
||||
</informalexample>
|
||||
|
|
Loading…
Reference in a new issue