<?php
$rate=array ( "M100B1000" => "40.00", "M1000B20000" => "80.00", "M500B10000" => "50.00", "MUnlimitedBUnlimited" => "240.00", "M5000BUnlimited" => "120.00 ") ;
ksort($rate);
print_r($rate);
?>
It gives sorting rate array..
M1000B20000
M100B1000
M5000BUnlimited
M500B10000
MUnlimitedBUnlimited
I Need this sorting..
M100B1000
M500B10000
M1000B20000
M5000BUnlimited
MUnlimitedBUnlimited
Give some ideas…
it looks like you want to sort it based on the size of the string if yes take a look at this example
more explanation here http://php.net/manual/en/function.sort.php