25
){ //$result = ".name,.pro require you to have an account to do whois searches."; $result = "Please contact us regarding $domain"; } else{ if (empty($this->whois_server)) { $parts = explode(".",$domain); $testhost = $parts[sizeof($parts)-1]; $whoisserver = $testhost . ".whois-servers.net"; $this->host = gethostbyname($whoisserver); $this->host = gethostbyaddr($this->host); if ($this->host == $testhost) { $this->host = "www.internic.net"; } } $whoisSocket = fsockopen($this->host,43, $errno, $errstr, $this->timeout); if (!$whoisSocket) { $result = STATS_DNSLOOKUP_ERROR."
".$errno." - ".$errstr."
"; } else { fputs($whoisSocket, $domain."