On 09/04/2011 21:30, Olof Johansson wrote:
On 2011-04-10 01:40 +0530, Sunita Rani Pradhan wrote:
You are right. Thanks for pointing out. Can you help me getting it
correct ?
Somebody already mentioned Regex::Common.
Use the same module for email addresses:
use Regexp::Common qw/ net Emai
On 2011-04-10 01:40 +0530, Sunita Rani Pradhan wrote:
> Hi Johan
s/Johan/Olof/, but who keeps score?
> You are right. Thanks for pointing out . Can you help me
> getting it correct ?
Somebody already mentioned Regex::Common.
--
- Olof Johansson
- www: http://www.stdlib.se/
-
Hi Johan
You are right. Thanks for pointing out . Can you help me
getting it correct ?
Thanks
Sunita
-Original Message-
From: Olof Johansson [mailto:o...@ethup.se]
Sent: Sunday, April 10, 2011 12:13 AM
To: beginners@perl.org
Subject: Re: regular expression for email id and IP
On 2011-04-09 23:53 +0530, Sunita Rani Pradhan wrote:
> Yes it is matching 167.249.0.0 .
But it's also matching things like "42". Feature?
Read about quantifiers, and also about the precedence of |.
--
- Olof Johansson
- www: http://www.stdlib.se/
- {mail,xmpp}: o...@ethup.se
- ir
use Regexp::Common qw/ net /;
$ip =~ /$RE{net}{IPv4}/;
Yes it is matching 167.249.0.0 .
-Sunita
-Original Message-
From: Jim Gibson [mailto:jimsgib...@gmail.com]
Sent: Saturday, April 09, 2011 11:50 PM
To: Perl Beginners
Subject: Re: regular expression for email id and IP address
At 11:42 PM +0530 4/9/11, Sunita Rani Pradhan wrote:
>Hi
At 11:42 PM +0530 4/9/11, Sunita Rani Pradhan wrote:
Hi All
1. Can anybody guide me to write a regular expression to
verify correct Email address ?
peldoc -q valid "How do I check a valid mail address?"
2. I have written a regular expression to verify correct
Hi All
1. Can anybody guide me to write a regular expression to
verify correct Email address ?
2. I have written a regular expression to verify correct IP address :
print $ipadd if ($ipadd =~
/^([0-9])|([1-9][0-9])|([1-2][0-5][0-5])\.([0-9])|([1-9][0-9])|([1-2