Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

php array_reverse keep keys


<?php
$input  = array("php", 4.0, array("green", "red"));
$reversed = array_reverse($input);
$preserved = array_reverse($input, true);

print_r($input);
print_r($reversed);
print_r($preserved);
?>

Source by www.php.net #
 
PREVIOUS NEXT
Tagged: #php #keys
ADD COMMENT
Topic
Name
5+9 =