Get the exact URL host name

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

Is there a way to know what exactly a hostname is?

Per example, we can have the domain « domain.qc.ca » and it could come in
one of those forms:

www.domain.qc.ca
sub.domain.qc.ca
domain.qc.ca

And so on...

I'd like to have only the name « domain.qc.ca ». Same thing for any domain
with any extension like .com, .net, .fr, .on.ca, or whatever the extension
could be

Any idea?

Thanks

Stephane
 
Back
Top