![]() |
|
Keep It Simple, Stupid | |
PerlMonks |
Extracting a domain name from a urlby abachus (Monk) |
on Oct 15, 2006 at 14:21 UTC ( #578383=perlquestion: print w/replies, xml ) | Need Help?? |
abachus has asked for the wisdom of the Perl Monks concerning the following question:
Good day all, I would like to extract a domain name from an arbitrary url. A nice easy example : From -> http://yahoo.co.uk/notfound.html extract only -> yahoo.co.uk The data will be coming from a UserAgent request header, so i will need to grab the GET *url* HTTP/1.1 line and work from there. Any thoughts on the best way to do this ? many thanks, Isaac Close.
Back to
Seekers of Perl Wisdom
|
|