Re: Re: get domain component from email
| From: | Dan | Date: | Tue, 07 Aug 2007 18:58:38 +0000 |
| Subject: | Re: Re: get domain component from email | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-260303@lists.php.net to get a copy of this message | ||
Well then he needs an array of ccTLD's and pretty much anything that can follow a domain name. In my previous code change the array you're giving it to be of ccTLD's and also you might want to pass that array in through the funciton. As I said, been a while since I did PHP.
- Dan
"Stut" <stuttle@gmail.com> wrote in message news:46B8BEF0.5050802@gmail.com...
Dan wrote:yes co.uk is a tdl.No it's not, it's a ccTLD which is a TLD specific to a country."Kevin Waterson" <kevin@oceania.net> wrote in message news:20070808042505.18ac7b4b.kevin@oceania.net...What are you actually trying to achieve? -Stut -- http://stut.net/Hi all. Im looking for a way to get the domain from an email address. Not sub domains, just the domain, so luser@foo.bar.example.com.mn would return example.com.mn similarly, the address luser@example.com would return example.com perhaps an array of tld's, then strip the tld off the end and anything before that and the next "." is the domain? also, somebody told me .co.uk was a tld, but I cannot see it listed http://www.iana.org/root-whois/index.html