Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: split split

by artist (Parson)
on Jun 23, 2009 at 21:56 UTC ( [id://774186]=note: print w/replies, xml ) Need Help??


in reply to split split

If you really need the 'ip address', you can use the right expression.
use Regexp::Common qw/net/; + my $ip_regexp = qr($RE{net {IPv4}); + while(<DATA>) { + if (/($ip_regexp)/) { + my $ip_address = $1; + print "$ip_address\n"; + } + } + + __DATA__ + client 127.0.0.1#47560: query: host.example.com IN AAAA +
--Artist

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://774186]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-04-24 04:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found