in reply to Matching an IP address
Unfortunately, most of the other useful-looking methods croak instead of returning undef on failure, so the documentation says you have eval 'em to handle strings with malformed addresses...use Net::IPv4Addr qw( :all ); if ($ip = ipv4_checkip($str)) { # do something }
|
---|