For first-time learning
Like this array_multisort ($arr 1, $arr 2, $arr 3); By default, all arrays are sorted in ascending order, and if you want to $arr2 in descending order and compare them as strings, write:
Array_multisort ($arr 1, $arr 2, Sort_desc, sort_string, $arr 3);
Each array can be followed by a sort order flag or a sort type flag, or both flags appear at the same time. However, each sort flag can only appear after each array.
PHP array_multisort sort order flag:
Sort_asc-Sort by ascending order (default)
Sort_desc-Sort by descending order
PHP Array_multisort Sort Type flags:
Sort_regular-Compare items by usual method (default)
Sort_numeric-Compare items by value
Sort_string-Compare items by string
http://www.bkjia.com/PHPjc/446072.html www.bkjia.com true http://www.bkjia.com/PHPjc/446072.html techarticle for first-time learning like this array_multisort ($arr 1, $arr 2, $arr 3); By default, all arrays are in ascending order, if you want to $arr2 descending, and as a string to compare, it should be written: ar ...