Sort problem

From: Date: Wed, 14 Sep 2011 14:48:51 +0000
Subject: Sort problem
Groups: php.general 
Request: Send a blank email to php-general+get-314844@lists.php.net to get a copy of this message
Hi Folks! Anyone know a smart way to order file names? An example to you guys picture what im saying is: <?php $serie[] = "Two And Half Man Season 1"; $serie[] = "Two And Half Man Season 4"; $serie[] = "Two And Half Man Season 2"; $serie[] = "Two And Half Man Season 3"; $serie[] = "Two And Half Man Season 10"; $serie[] = "Two And Half Man Season 9"; sort($serie); print_r($serie); ?> The result of this snippet is: Array ( [0] => Two And Half Man Season 1 [1] => Two And Half Man Season 10 [2] => Two And Half Man Season 2 [3] => Two And Half Man Season 3 [4] => Two And Half Man Season 4 [5] => Two And Half Man Season 9 ) Anyone knows how to solve this problem? Regards, Igor Escobar *Software Engineer * + http://blog.igorescobar.com + http://www.igorescobar.com + @igorescobar <http://www.twitter.com/igorescobar>

« previous php.general (#314844) next »