#25836 [Com]: strange behavior magic_quotes with multi-dimensional arrays

From: Date: Mon, 13 Oct 2003 11:02:31 +0000
Subject: #25836 [Com]: strange behavior magic_quotes with multi-dimensional arrays
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-48908@lists.php.net to get a copy of this message
ID: 25836 Comment by: tony2001 at phpclub dot net Reported By: sitnikov at infonet dot ee Status: Verified Bug Type: *General Issues Operating System: Linux PHP Version: 4CVS, 5CVS New Comment: I've reproduced it with latest CVS. Pearsonally I really don't see any reasons to quote array indices in this case, but there is two possible ways: PHP should quote 1) all of them; 2) none of them. and, as you can see, none of these ways are working with magic_quotes_gpc=On Previous Comments: ------------------------------------------------------------------------ [2003-10-12 23:12:12] sniper@php.net Nevermind, had of course set magic_quotes_gpc = On. ------------------------------------------------------------------------ [2003-10-12 23:03:30] sniper@php.net Can not reproduce with latest STABLE CVS. Please provide more information how to reproduce. ------------------------------------------------------------------------ [2003-10-11 08:57:34] sitnikov at infonet dot ee Description: ------------ Only "first level keys" was slashed. Reproduce code: --------------- <? echo "<pre>";print_r($_POST);echo "</pre>"; ?> <form method="POST"> <input type=text name="test['aaa']['bbb']" value="'"> <input type=submit> </form> Expected result: ---------------- Array ( [test] => Array ( [\'aaa\'] => Array ( [\'bbb\'] => \' ) ) ) Actual result: -------------- Array ( [test] => Array ( [\'aaa\'] => Array ( ['bbb'] => \' ) ) ) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=25836&edit=1

« previous php.bugs (#48908) next »