ID: 24565 User updated by: nightcat at poczta dot onet dot pl Reported By: nightcat at poczta dot onet dot pl Status: Verified Bug Type: Zend Engine 2 problem Operating System: * PHP Version: 5.0.0b2-dev New Comment:
Any chance to have this fixed before next beta? Previous Comments: ------------------------------------------------------------------------ [2003-07-09 16:00:13] [EMAIL PROTECTED] Reproduced with latest PHP 5 CVS. Works fine with PHP 4.3.3RC2-dev. ------------------------------------------------------------------------ [2003-07-09 15:05:28] tingle at virtuanews dot co dot uk Confirmed using Apache 2.0.46, Windows XP SP1 and the latest snapshot (php5-win32-200307091830.zip) Identical problem as stated print_r() gives the expected output with the expected keys and values, however, trying to reference the key within the code results in it not being set ------------------------------------------------------------------------ [2003-07-09 11:16:27] nightcat at poczta dot onet dot pl Description: ------------ In PHP5 yesterdays snapshot i'm unable to get array element created by POST/GET method. Reproduce code: --------------- <? if (isset($_REQUEST['arr1'])) { print_r($_REQUEST['arr1']); // displays key and value. print('test1: '.$_REQUEST['arr1'][0]); // error print_r(array_keys($_REQUEST['arr1'])); // returns one index: '0' } ?> <html> <head> <title> TestCase </title> </head> <body> <form method=post action=""> test1: <input type="checkbox" name="arr1[0]" value="1" /><br /> <input type="submit" /> </form> </body> </html> Expected result: ---------------- test1: 1 Actual result: -------------- Notice: Undefined offset: 2 in D:\server\www\test\php5\index.phtml on line 4 test1: ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=24565&edit=1