Re: [PHP] Re: reading/parsing file names

2003-10-26 Thread Curt Zirzow
* Thus wrote Evan Nemerson ([EMAIL PROTECTED]): [tadpole tadpole]$ php -q ./bench.php Averages: substr: 3.5071199059486 pcre: 4.2237901210785 Averages: substr: 5.1445327162743 pcre: 5.6803694009781 posix: 8.0486606121063 Interesing that my results of substr vs. pcre came in closer,

[PHP] Re: reading/parsing file names

2003-10-25 Thread koly
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Koly) wrote: my problem: I've got a list of files in a directory, and I'd like to get a only of filenames that end in .jpg, however, exlude the files that end in .thumb.jpg ex: file.php index.htm photo.jpg photo.thumb.jpg etc

Re: [PHP] Re: reading/parsing file names

2003-10-25 Thread John Nichel
koly wrote: In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Koly) wrote: my problem: I've got a list of files in a directory, and I'd like to get a only of filenames that end in .jpg, however, exlude the files that end in .thumb.jpg ex: file.php index.htm photo.jpg photo.thumb.jpg etc how

Re: [PHP] Re: reading/parsing file names

2003-10-25 Thread Eugene Lee
On Sat, Oct 25, 2003 at 04:16:49PM -0700, koly wrote: : : [EMAIL PROTECTED] (Koly) wrote: : : I've got a list of files in a directory, and I'd like to get a only of : filenames that end in .jpg, however, exlude the files that end in : .thumb.jpg : : ex: : file.php : index.htm :

Re: [PHP] Re: reading/parsing file names

2003-10-25 Thread Evan Nemerson
A little something I whipped up to avoid my zoology homework (I /really/ don't care that the damn sperm of nematodes are unusual because they lack a flagellum and acrosome). Conclusion: substr is faster than preg_match [tadpole tadpole]$ php -q ./bench.php substr: 3.6424000263214 PCRE: