if ( $plup =~ /\.(gif|jpg)$/i ) {
#
# This is success(ie, name ends with a . and either gif or jpg)
Ignore case
#
}else {
# not a gif or jpg
}
Wags ;)
-----Original Message-----
From: Troy May [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 02, 2002 22:58
To: Perl Beginners
Subject: Regex help!
Please... :)
Hello, I'm trying to match images by the extension. Either .jpg or .gif
Here's what I wrote:
$plup =~ m/\(\^\.\.gif\|\^\.\.jpg)/\
Is it all screwed up? I'm not real good with regexes.
Thanks if you can help me!
Troy
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]