note 81385 added to function.uniqid
| From: | mark at whytewaters dot com | Date: | Tue, 26 Feb 2008 02:39:10 +0000 |
| Subject: | note 81385 added to function.uniqid | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-136484@lists.php.net to get a copy of this message | ||
If you want many ids and performance of this function is an issue why not pull uniquid() out of the
loop, eg:
$base = uniqueid();
$ids[] = array();
for ($index = 0; $index < 100000; $index++)
$ids[] = $base . '.' . $index;
----
Server IP: 203.89.181.186
Probable Submitter: 202.124.96.67
----
Manual Page -- http://www.php.net/manual/en/function.uniqid.php
Edit -- https://master.php.net/note/edit/81385
Del: integrated -- https://master.php.net/note/delete/81385/integrated
Del: useless -- https://master.php.net/note/delete/81385/useless
Del: bad code -- https://master.php.net/note/delete/81385/bad+code
Del: spam -- https://master.php.net/note/delete/81385/spam
Del: non-english -- https://master.php.net/note/delete/81385/non-english
Del: in docs -- https://master.php.net/note/delete/81385/in+docs
Del: other reasons-- https://master.php.net/note/delete/81385
Reject -- https://master.php.net/note/reject/81385
Search -- https://master.php.net/manage/user-notes.php