#32569 [Opn->Bgs]: array_rand problem with length of array
ID: 32569
Updated by: betz@php.net
Reported By: mail at sebastianburg dot de
-Status: Open
+Status: Bogus
Bug Type: Arrays related
Operating System: Linux
PHP Version: 4.3.10
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
Try increasing your error_reporting level.
Make sure, to not pick more random values as your array holds elements.
Previous Comments:
------------------------------------------------------------------------
[2005-04-04 16:06:16] mail at sebastianburg dot de
Description:
------------
array_rand($array,$num);
if $num > count($array) the return of array_rand is NULL
Reproduce code:
---------------
http://code.smb-media.de/?nr=5
http://code.smb-media.de/show/array_rand.php
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=32569&edit=1
Thread (2 messages)