Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Extract Host, Logical Host from URL

by andreas1234567 (Vicar)
on Aug 15, 2007 at 05:35 UTC ( [id://632653]=note: print w/replies, xml ) Need Help??


in reply to Extract Host, Logical Host from URL

You mean something like this?
use strict; use warnings; print m/^.*?(\w+\.\w+)$/ while(<DATA>); __DATA__ shopping.yahoo.com yahoo.com some.very.long.url.at.yahoo.com
$ perl -l 632539.pl yahoo.com yahoo.com yahoo.com
--
Andreas

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (2)
As of 2024-03-19 06:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found