I want to sort a multidimensional array in PHP, based on one of its value.
For example
$shop = array( array("rose", 3 , 'rr'),
array("daisy", 1 , 'dd'),
array("orchid", 2 , 'oo')
);
I want to sort this array based on 3,1,2 . i.e I want to sort this array in to
$shop = array( array("daisy", 1 , 'dd'),
array("orchid", 2 , 'oo'),
array("rose", 3 , 'rr')
);
Please any one help me! Is there are is any function in PHP to do this?