ParseUtil::Domain(3) User Contributed Perl Documentation ParseUtil::Domain(3) N�NA�AM�ME�E ParseUtil::Domain - Utility for parsing a domain name into its constituent components. S�SY�YN�NO�OP�PS�SI�IS�S use ParseUtil::Domain; my $processed = parse_domain("somedomain.com"); # $processed == { # domain => 'somedomain', # domain_ace => 'somedomain', # zone => 'com', # zone_ace => 'com' # } D�DE�ES�SC�CR�RI�IP�PT�TI�IO�ON�N Just another tool for parsing domain names. This module makes use of the data provided by the _�P_�u_�b_�l_�i_�c _�S_�u_�f_�f_�i_�x _�L_�i_�s_�t (http://publicsuffix.org/list/) to parse tlds. For completeness it tries to provide the respective puny encoded and decoded domain and tld part of a domain name. This includes proper handling of the L�LA�AT�TI�IN�N S�SH�HA�AR�RP�P S�S which is now allowed by DENIC eG (.de). I�IN�NT�TE�ER�RF�FA�AC�CE�E p�pa�ar�rs�se�e_�_d�do�om�ma�ai�in�n Arguments "string" Examples: 1. 'somedomain.com' 2. 'test.xn--o3cw4h' 3. 'bloss.co.at' 4. 'bloss.de' Return "HASHREF" Examples: 1. { domain => 'somedomain', zone => 'com', domain_ace => 'somedomain', zone_ace => 'com' } 2. { domain => 'test', zone => 'XXX', domain_ace => 'test', zone_ace => 'xn--o3cw4h' } 3. { domain => 'bloss', zone => 'co.at', domain_ace => 'bloss', zone_ace => 'co.at' } 4. { domain => 'bloss', zone => 'de', domain_ace => 'xn--blo-7ka', zone_ace => 'de' } D�DE�EP�PE�EN�ND�DE�EN�NC�CI�IE�ES�S Net::IDN::Encode Net::IDN::Punycode Regexp::Assemble::Compressed The Public Suffix List at http://publicsuffix.org/list/ B�BU�UG�GS�S Although, not necessarily a bug, be wary of differences in encoding/decoding domains ending in .�.d�de�e. These domains are not _�n_�a_�m_�e_�p_�r_�e_�ped like other tlds in order to allow for encoding of the German L�LA�AT�TI�IN�N S�SH�HA�AR�RP�P S�S. perl v5.10.1 2011-01-26 ParseUtil::Domain(3)