Answers for "php print top n of array"

PHP
0

php print top n of array

//arsort($myArray); //sort if you need to then
print_r(array_slice($myArray, 0, 10));//print top 10 item in array
Posted by: Guest on August-12-2021

Browse Popular Code Answers by Language