PX : code

Case insensitive alphabetical array sorter by Richard Heyes
Download this code


<?php
        
function isort($a,$b){
                if(
ord(substr(strtolower($a),0,1)) == ord(substr(strtolower($b),0,1))) return 0;
                return (
ord(substr(strtolower($a),0,1)) < ord(substr(strtolower($b),0,1))) ? -1;
        }
?>

Comments or questions?
PX is running PHP 5.2.17
Thanks to Miranda Productions for hosting and bandwidth.
Use of any code from PX is at your own risk.