ID: 31599 User updated by: vortexx at freemail dot hu Reported By: vortexx at freemail dot hu -Status: Feedback +Status: Closed Bug Type: Arrays related Operating System: Windows 2000 SP4 PHP Version: 5.0.2 New Comment:
In the latest snapshot array_walk_recursive (and the sample code I provided here) works fine, so it seems the problem only existed in PHP 5.0.2 (perhaps in the win version only?) Thanks! Previous Comments: ------------------------------------------------------------------------ [2005-01-18 16:59:57] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.0-win32-latest.zip ------------------------------------------------------------------------ [2005-01-18 16:52:46] vortexx at freemail dot hu Description: ------------ array_walk_recursive simply refuses to do anything whatsoever (even with the example code in the PHP docs!), while array_walk works fine. Please note: I am using PHP 5.0.2 and not PHP5.0.3 because I am unable to us ethe latter due to another bug I reported, still open here: http://bugs.php.net/bug.php?id=31175 Reproduce code: --------------- (taken from http://www.php.net/manual/en/function.array-walk-recursive.php) $sweet = array('a' => 'apple', 'b' => 'banana'); $fruits = array('sweet' => $sweet, 'sour' => 'lemon'); function test_print($item, $key) { echo "$key holds $item\n"; } array_walk_recursive($fruits, 'test_print'); Expected result: ---------------- a holds apple b holds banana sour holds lemon Actual result: -------------- [nothing, just blank!] ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31599&edit=1
