To answer your original question: No, there is no default PHP function for this. However, you can try some combinations of other functions described by other guys. However, I find the following code fragment more readable:
$numbers = Array( "a" => "1", "b" => 2, "c" => 3 ); foreach ( $numbers as &$number ) { $number = 0; }
source share