PHP array_multisort() Function

The array_multisort() function is used to sort multiple arrays or a multidimensional array by one or more dimensions.The array_multisort() function returns a sorted array. You can assign one or more arrays. The function sorts the first array, and the other arrays follow, then, if two or more values are the same, it sorts the next array, and so on.

Example -

Example -