Forum Moderators: coopster
I wrote this function thinking I'd bypass this, but it (surprisingly) only worked with user functions and halted execution on native php functions!
function walk_it (&$array, $func){
foreach($array as $key => $val){
$func($array[$key]);
}
}
Everytime I code I need to process arrays. How could I accomplish something as basic as this (without looping manually)?:
* array_walk($array, 'addslashes');
* array_walk($array, 'print');