* Shabam:
> How do you fetch just the domain name part of a variable in a script? The
> variable can be "http://www.domain.com/blahblah/whatever/page.htm" or
> "http://sub.domain.com/blahblah/whatever/page.htm".
>
> What I need is to extract just the "domain.com".
try something like:
my(undef, undef, $domain) = $s =~
/^(http|ftp|whatever):\/\/(www|ftp|whatever)\.(.+?)\//;
There might be some module that does what you're looking for (check
CPAN), I didn't look for it, actually...
bye
//Dave
--
Ja, der typische "Ich tippe alles ein was mir ein paar Trottel aus dem
IRC sagen"-Newbie wird aber kein Solaris nutzen...

-- Christoph Gebhardt in bjt