Array Question (Sorting) - Same but different

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

Post Reply
jasonthomasfrance
New php-forum User
New php-forum User
Posts: 6
Joined: Fri Jan 03, 2003 3:07 am
Contact:

Post by jasonthomasfrance » Mon Jan 06, 2003 11:16 pm

Howdy,

Something like this won't work for you:

arsort($images,SORT_NUMERIC);

That line sorts my array by date (newest to oldest). I would suppose you'd have to get the file info with: if(is_file($file))$images[$file]=filemtime($file);

Does that sound right?

Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests