array_reverse
PHP 4, PHP 5, PHP 7, PHP 8
array_reverse - Return an array with elements in reverse order
Example #1 array_reverse example
Result: Array
(
[0] => php
[1] => 4
[2] => Array
(
[0] => green
[1] => red
)
)
Array
(
[0] => Array
(
[0] => green
[1] => red
)
[1] => 4
[2] => php
)
Array
(
[2] => Array
(
[0] => green
[1] => red
)
[1] => 4
[0] => php
)
Example #2 of array_reverse