Re: [PHP] sorting an array..dont know numeric or alpha-numeric

2004-08-07 Thread Kevin Waterson
This one time, at band camp, PHP Gen <[EMAIL PROTECTED]> wrote: > Hi, > I have a function that reads jpg files (thumbnails) > from a directory and puts all the files names into an > array...I want to sort that array by the filename, > problem is, I dont know if filenames will be pure > numeric (eg

Re: [PHP] sorting an array..dont know numeric or alpha-numeric

2004-08-06 Thread PHP Gen
Hi Curt, Damn, looks like I (unintentionally) gave you guys quite a challenge! You're the first one to reply and looks like you sure worked on it! > For starters, if your going to provide some code, > make sure its > readable by others.. trying to figure out what it is > doing is > nearly impossi

Re: [PHP] sorting an array..dont know numeric or alpha-numeric

2004-08-06 Thread Curt Zirzow
* Thus wrote PHP Gen: >... > > Looking in the manual I have tried sort() without any > luck, then looking further I found natcasesort() which > would be perfect for my needs right now, but cant get > it to work :-( > > Below is the function (its not big) > > *** Start function *

[PHP] sorting an array..dont know numeric or alpha-numeric

2004-08-06 Thread PHP Gen
Hi, I have a function that reads jpg files (thumbnails) from a directory and puts all the files names into an array...I want to sort that array by the filename, problem is, I dont know if filenames will be pure numeric (eg 001.jpg,002.jpg) or alpha-numeric (asdf001,asdf002) It HAS to be sequential