develooper Front page | perl.beginners | Postings from January 2002

pattern matching for ip addresses in a text file

Thread Next
From:
Ken Yeo
Date:
January 7, 2002 07:29
Subject:
pattern matching for ip addresses in a text file
Message ID:
20020107152905.52585.qmail@onion.perl.org
Hi,

What is the best pattern matching for ip addresses? I tried $var =~
/\b\d{1-3}\.\d{1-3}\.\d{1-3}\.\d{1-3}\s/ but the {1-3} didn't work, please
advise, TIA!

Ken Yeo



Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About