Name

sort

Synopsis

$sorted_array = sort($array)

Returns a sorted copy of the nonassociative array array in ascending order. If the first member of the array is a number, the returned array will be sorted numerically, otherwise the returned array will be sorted alphabetically.

Get MySQL and mSQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.