sorting directory contents
| From: | Wizaerd | Date: | Mon, 11 Sep 2000 00:49:29 +0000 |
| Subject: | sorting directory contents | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-16098@lists.php.net to get a copy of this message | ||
I'm building a script that reads an image directory, outputting the name of
the image, the dimensions of the image as well as it's size. It's using
opendir() and readdir(), but readdir() doesn't return the directory back in
any particular order. I'm not storing the results to an array because
ultimately there could be thousands of images, and I'd like to save the
memory overhead of building then sorting such a large array.
So is there anyway to just read the results of an opendir() that is sorted
by filename?
Thanx!
Joseph E. Sheble
a.k.a. Wizaerd
Wizaerd's Realm
Canvas, 3D, Graphics, ColdFusion
http://www.wizaerd.com
=================================