PHP: sorting a multidimentional array ($arr[$i]['v'])

后端 未结 1 601
心在旅途
心在旅途 2020-12-22 11:02

i have array in type of (UNSORTED VERSION):



        
相关标签:
1条回答
  • 2020-12-22 11:51

    Use this function:

    uasort($yourArray, function($a, $b) {
        return strcmp($a['man'], $b['man']);
    });
    

    Or look at array_multisort

    0 讨论(0)
提交回复
热议问题