php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #37840
Patch Uniqid revision 2010-04-22 06:32 UTC by mwoolf at mcomi dot net

Patch Uniqid for Performance problem Bug #37840

Patch version 2010-04-22 06:32 UTC

Return to Bug #37840 | Download this patch
Patch Revisions:

Developer: mwoolf@mcomi.net

To patch this problem simply set $more_entropy to true

string uniqid ([ string $prefix = "" [, bool $more_entropy = false ]] )

so

unqid($your_prefix, true); // Quick

as opposed to 

uniqid($your_prefix); // Takes too long to generate

We had this problem on CentOS 5 using PHP 5.2
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 10:01:28 2024 UTC