Bug #17129 Updated: Shuffle doesn't work just in first two itens of array
| From: | tal@php.net | Date: | Thu, 04 Jul 2002 18:47:32 +0000 |
| Subject: | Bug #17129 Updated: Shuffle doesn't work just in first two itens of array | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-13134@lists.php.net to get a copy of this message | ||
ID: 17129
Updated by: tal@php.net
Reported By: cristian@siens.com.br
-Status: Open
+Status: Verified
Bug Type: Arrays related
Operating System: Windows 2000
PHP Version: 4.2.1
New Comment:
Okay, verified with 4.3.0-dev snapshot from July 4th.
-Tal
Previous Comments:
------------------------------------------------------------------------
[2002-07-04 14:46:38] sniper@php.net
oops..I tested with Linux. No idea of win32.
------------------------------------------------------------------------
[2002-07-04 14:45:33] sniper@php.net
Works fine with latest CVS (HEAD, 4.3.0-dev).
------------------------------------------------------------------------
[2002-07-04 14:05:11] eru@php.net
Verified during the Bughunt. Seems to work with 4.1.1
------------------------------------------------------------------------
[2002-05-09 16:53:59] cristian@siens.com.br
The function does not execute in the two first itens of the Array. Let
us see the code below:
<?
$banner[0]="value1";
$banner[1]="value2";
$banner[2]="value3";
$banner[3]="value4";
$banner[4]="value5";
$banner[5]="value6";
shuffle($banner);
echo $banner[0];
?>
The function always shows the value of second element, but if I to
change the value for $banner[2] or higher, the function works, but
don´t use the first two elements.
This function works perfectly in another Linux server with php 4.1.2.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17129&edit=1