sanjay nayak has asked for the wisdom of the Perl Monks concerning the following question:
Hi Monks
Plz suggest me a suitable Regular expression for the following conditions.
REGISTER or INVITE or BYE (space) some text or digit or both -(hypen) or @ or _(underscore sign) some text or digit or both . some text or digit or both space SIP/2.0.
For example
my $text="REGISTER acti-abc.test SIP/2.0";
If ($text ~= /^REGISTER|INVITE|BYE\s\w\.\w\sSIP\/2.0/)
The above is not working properly, Plz suggest me a suitable regular expression for the above.
Regd's Sanjay
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: What is regular expression for the following thing?
by ikegami (Patriarch) on Oct 20, 2008 at 09:07 UTC | |
Re: What is regular expression for the following thing?
by Corion (Patriarch) on Oct 20, 2008 at 09:08 UTC | |
Re: What is regular expression for the following thing?
by pysome (Scribe) on Oct 20, 2008 at 09:40 UTC | |
Re: What is regular expression for the following thing?
by Punitha (Priest) on Oct 20, 2008 at 09:13 UTC | |
by ikegami (Patriarch) on Oct 20, 2008 at 09:18 UTC | |
Re: What is regular expression for the following thing?
by luckypower (Beadle) on Oct 20, 2008 at 09:13 UTC |
Back to
Seekers of Perl Wisdom