> -----Original Message-----
> From: jas [mailto:[EMAIL PROTECTED]]
> Sent: 11 April 2002 11:34
>  while ($file_names = readdir($dir)) {
>   if ($file_names != "." && $file_names !=".." && 
> ereg('_(^[0-9]{4}.jpg$)',

OK, let's take a close, step-by-step look at this ereg pattern:

  _  OK -- matches an underscore
  (  OK -- just a group opener
  ^  uh-oh -- only matches the *start* of the string, so will always fail!

As far as I can see, you don't need that caret in there at all -- it's not as if 
you're even trying to negate the bracketed range which follows.

Cheers!

Mike

---------------------------------------------------------------------
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730      Fax:  +44 113 283 3211 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to