Liodel Posted July 31, 2008 Share Posted July 31, 2008 I just want to know if there is an easier way to sort files in a directory by date than using filemtime and sorting through array, or is there any straight forward function for it? Thank you for your ideas, codes snippet will be better. Link to comment https://forums.phpfreaks.com/topic/117467-sort-files-by-date-in-a-directory-anyone-knows-a-straight-forward-function/ Share on other sites More sharing options...
Third_Degree Posted July 31, 2008 Share Posted July 31, 2008 I don't really know any. I think the only other option is stat(), but that's still sorting through an array. What's wrong with sorting through arrays though? Link to comment https://forums.phpfreaks.com/topic/117467-sort-files-by-date-in-a-directory-anyone-knows-a-straight-forward-function/#findComment-604246 Share on other sites More sharing options...
Liodel Posted July 31, 2008 Author Share Posted July 31, 2008 There's nothing wrong actually I just want to know if I'm doing it the right way. Thanks by the way for the reply. Link to comment https://forums.phpfreaks.com/topic/117467-sort-files-by-date-in-a-directory-anyone-knows-a-straight-forward-function/#findComment-604286 Share on other sites More sharing options...
Third_Degree Posted August 1, 2008 Share Posted August 1, 2008 Well yeah, that's the way I'd do it. Link to comment https://forums.phpfreaks.com/topic/117467-sort-files-by-date-in-a-directory-anyone-knows-a-straight-forward-function/#findComment-605309 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.