Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: extract a hostname from a fqdn

by rjt (Deacon)
on Mar 23, 2013 at 23:46 UTC ( #1025095=note: print w/replies, xml ) Need Help??


in reply to extract a hostname from a fqdn

/^ ([^.]+) (?:\.(.+))? $/x; say "Host: `$1', domain: `$2'";

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1025095]
help
Chatterbox?
[Tanktalus]: Tux: usually, yes. :P
[choroba]: Interesting Regexp::Debugger issue

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2017-09-25 21:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (291 votes). Check out past polls.

    Notices?