array walk in php code example
Example: php array_walk
$arr = array(1, 2, 3);
// Call function on every item.
// Sign $item as reference to work on original item.
array_walk($arr, function(&$item, $key, $myParam){
$item *= 2;
}, 'will be in myParam');
// $arr now is [2, 4, 6]