natcasesort

It sorts an array using a case insensitive “natural order” algorithm

Example

<?php
echo “<pre>”;
$lan = array(“PHP”,”ASP”,”JSP”);
natcasesort($lan);
print_r($lan);
?>

Output

Array
(
[1] => ASP
[2] => JSP
[0] => PHP
)

Share