Net::Domain::TLD3pm
Usage
use Net::Domain::TLD qw(tlds tld_exists);my @ccTLDs = tlds('cc');print "TLD ok\n" if tld_exists('ac','cc');
Overview
The purpose of this module is to provide user with current list ofavailable top level domain names including new ICANN additions and ccTLDsCurrently TLD definitions have been acquired from the following sources:http://www.icann.org/tlds/http://www.dnso.org/constituency/gtld/gtld.htmlhttp://www.iana.org/cctld/cctld-whois.htmhttps://www.iana.org/domains/root/db
Public methods
Each public function/method is described here.These are how you should interact with this module.
"tlds"
This routine returns the tlds requested.my @all_tlds = tlds; #array of tldsmy $all_tlds = tlds; #hashref of tlds and their descriptionsmy @cc_tlds = tlds('cc'); #array of just 'cc' type tldsmy $cc_tlds = tlds('cc'); #hashref of just 'cc' type tlds and their descriptionsValid types are:cc - country code domainsccidn - internationalized country code top-level domaingtld_open - generic domains that anyone can registergtld_restricted - generic restricted registration domainsgtld_new - new gTLDsnew_open - recently added generic domainsnew_restricted - new restricted registration domainsreserved - RFC2606 restricted names, not returned by tlds
"tld_exists"
This routine returns true if the given domain exists and false otherwise.die "no such domain" unless tld_exists($tld); #call without tld typedie "no such domain" unless tld_exists($tld, 'new_open'); #call with tld type
Releases
11 releases since Debian 3.1 (Sarge); the text changed 9 times.