Re: [PBML] Regex Help
- On Sun, 23 Aug 1998 17:26:17 -0500, hdesign <hdesign@...> wrote:
>$_='My email address is <<<web@...>.';Here's what you want:
>print "$_ \n";
>print "Match worked :$1:\n" if /(<*>)/i;
$_='My email address is <<<web@...>.';
print "$_ \n";
print "Match worked :$1:\n" if /<([^<]*)>/i;
< - matches a literal '<'
() - contains the pattern returned in $1
* - defines a class of characters matched as a string
^< - matches anything BUT a '<'
So the pattern says "Match '<', then zero or more characters which aren't a '<',
and finally a '>'."
~~~~~~~~~~~~~~~~|Fare Thee well now, let your
Jeffery Boes |life proceed by its own design.
jboes@... |Nothing to tell now, let your
UIN 3394914 |words be yours, I'm done with mine...
List Site: http://www.findmail.com/list/perl-beginner/
To unsubscribe, send to perl-beginner-unsubscribe@...
FREE group e-mail lists at http://www.findmail.com