Domain Name Query Code announcement
<?php
Network Technology Director motto: Three people line, it must have my teacher Yan. Http://www.ctohome.com
This code can be said to be very smart, I changed a small part to make it easier to use.
$moreinfolist = Array (//storage of WHOIS query host connection method
' At ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Au ' => ' www.aunic.net/cgi-bin/whois.aunic ',
' BM ' => ' www.bermudanic.bm/cgi-bin/BermudaNIC/rwhois_query_get.pl?query_text= ',
' ch ' => ' www.switch.ch/cgi-bin/domain/search_domain?keyword= ',
' com ' => ' www.networksolutions.com/cgi-bin/whois/whois/?STRING= ',
' CZ ' => ' www.ripe.net/cgi-bin/whois?query= ',
' De ' => ' www.ripe.net/cgi-bin/whois?query= ',
' DK ' => ' www.ripe.net/cgi-bin/whois?query= ',
' edu ' => ' www.networksolutions.com/cgi-bin/whois/whois/?STRING= ',
' es ' => ' www.nic.es/whois/index.php?type=Dominios&key= ',
' fi ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Fo ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Fr ' => ' harmonic.nic.fr/cgi-bin/harmonic.pl? Annu_suffixe=&annu_action=rechercher&annu_automaton_state=17&annu_motif= ',
' GL ' => ' www.ripe.net/cgi-bin/whois?query= ',
' GM ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Gov ' => ' www.nic.gov/cgi-bin/whois?s=nic.gov ',
' gr ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Hu ' => ' www.ripe.net/cgi-bin/whois?query= ',
' id ' => ' whois.idnic.net.id/cgi-bin/whois-cgi?user= ',
' IE ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Il ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Is ' => ' www.ripe.net/cgi-bin/whois?query= ',
' It ' => ' www.ripe.net/cgi-bin/whois?query= ',
' JP ' => ' www.nic.ad.jp/cgi-bin/whois_gw?lang=/e&type=DOM&rule=ex&key= ',
' lb ' => ' www.aub.edu.lb/cgi-bin/lbdr.pl?cn= ',
' Li ' => ' www.switch.ch/cgi-bin/domain/search_domain?keyword= ',
' Lt ' => ' www.ripe.net/cgi-bin/whois?query= ',
' LV ' => ' www.ripe.net/cgi-bin/whois?query= ',
' MC ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Mil ' => ' www.nic.mil/cgi-bin/whois?stype=Domains&ctype=reg&keyword= ',
' Ms ' => ' www.adamsnames.tc/whois/?seen=y&domain= ',
' MX ' => ' Www.nic.mx/cgi/whois? ',
' Net ' => ' www.networksolutions.com/cgi-bin/whois/whois/?STRING= ',
' No ' => ' www.ripe.net/cgi-bin/whois?query= ',
' NZ ' => ' www.domainz.net.nz/facility/namesearch/Result.asp?prmMode=Search&DomainName= ',
' org ' => ' www.networksolutions.com/cgi-bin/whois/whois/?STRING= ',
' PT ' => ' www.ripe.net/cgi-bin/whois?query= ',
' Ro ' => ' whois.rotld.ro/cgi-bin/whois?whois= ',
' SK ' => ' www.ripe.net/cgi-bin/whois?query= ',
' SM ' => ' www.ripe.net/cgi-bin/whois?query= ',
' TC ' => ' www.adamsnames.tc/whois/?seen=y&domain= ',
' TF ' => ' www.adamsnames.tc/whois/?seen=y&domain= ',
' th ' => ' www.thnic.net/cgi-bin/whois.pl?server=whois.thnic.net&string= ',
' TJ ' => ' Www.nic.tj/whois.cgi?domain ',
' tr ' => ' Whois.cc.metu.edu.tr/whois/wwwwhois? Whois= ',
' UK ' => ' www.nic.uk/cgi-bin/whois.cgi?query= ',
' VA ' => ' www.ripe.net/cgi-bin/whois?query= ',
' VG ' => ' www.adamsnames.tc/whois/?seen=y&domain= '
);
# where can we get more info?
$moreinfo = FALSE;
for (Reset ($moreinfolist); list ($tail, $moreinfoname) = each ($moreinfolist);
if (eregi ("\. $tail $", $address)) {//compare domain name suffix
$moreinfo = $moreinfoname; End loop immediately when a match is encountered
Break
}
if ($moreinfo && $address) {//jump to WHOIS host
Header (' location:http://'. $moreinfo. $address);
Exit ();
}
else {
echo "<form action= $PHP _self method=post>
Please enter the domain name: <input name=address>
<input type=submit></form> ";
}
?>
<title>whois tool</title>
<body>
<p> Network Technical Supervisor Chinese interpretation </a>.</p>
<address>http://www.ctohome.com</address>
</body>
<?php
Highlight_file ("whois.php");
?>