Use PHP to query the domain name status whois class
The code is as follows:
Class SearchDomain{Var $ domain = "";Function SetDomain ($ udomain){$ This-> domain = $ udomain;}//// Obtain whois and analyze the domain name status// OK is not registered// Non-null expiration time// Null value unknown//Function GetInfo (){/*$ Dinfo = trim ($ this-> GetWhois ());If ($ dinfo = "") return "";If (eregi ("no match
Php method of querying whois information, Phpwhois information method
In this paper, we explain how to query whois information in PHP. Share to everyone for your reference. Specific as follows:
Use PHP to query the list of websites that query whois information
function Whois_query ($domain) {//fix the domain name: $domain = Strtolower (Trim ($domain)); $domain
Copy CodeThe code is as follows:
Class Searchdomain
{
var $domain = "";
function SetDomain ($udomain)
{
$this->domain = $udomain;
}
//
Get whois and analyze domain name status
OK is not registered
Non-null value expiration time
Null value Unknown
//
function GetInfo ()
{
/*
$dinfo = Trim ($this->getwhois ());
if ($dinfo = = "") return "";
if (eregi ("No Match", $dinfo)) return "OK";
return $rs;
*/
$WL = "";
$w _server = $this->getserver ();
if ($w _s
Function 1:// Hichina whois (the interfaces used provide valid interfaces for hichina)Function whois_hichina ($ domain ){Preg_match ("| $ Whois [0] = str_replace (Note: as required by the Registry, expired domain names may be in the automatic renewal phase of the Registrar, the domain name expiration date you see here is for reference only Return $ whois [0];}//
In the whois++ structure, the customer is responsible for the network roaming, because each host only informs the customer and its neighboring host is what, this protocol is not complex, the customer opens to a server connection, sends the inquiry request, receives the reply, closes the connection. The customer analyzes after receiving the reply, and then decides which host to contact next. This allows the customer to have an algorithm that allows the
Whois information will be obtained from the WHOIS query and stored in the database
specific methods But more elaborate
write the domain name or match the offending domain name to the database where the request occurred
"'--------------------------ver:2.0 date:2017/11/22 auth:wud---------------------- ----' Import DNS import mysqldb import whois import sys from
Previously in the PHP host domain name program used by a WHOIS check code to determine whether the domain name being queried is registered, the function includes most of the domain name suffix, will be based on the suffix of the different connections to different query server, previously can use, time relationship, I am not currently testing those query URLs are still available, if not, you need to find information on your own to see what the current
Million web whois (using the interface for the million network to provide a legitimate interface)
Copy Code code as follows:
function Whois_hichina ($domain) {
Preg_match ("|$whois [0] = str_replace (' Friendship tip: According to the requirements of the registration Board, the expired domain name may be in the Registrar automatic renewal phase, you see the domain name due date in this que
JJX original, reprint must indicate the source
To copy code, use the forum's "copy" feature to complete
Chinaasp's domain name query to sell 1000 yuan, netizens made comments, but was Lucot a sentence (you put him packaged into components to try?) ) was blocked back. Domain name registration query (WHOIS) is it really complicated?
Domain name registration query is mainly through the WHOIS server to complet
Copy Code code as follows:
?
Class Searchdomain
{
var $domain = "";
function SetDomain ($udomain)
{
$this->domain = $udomain;
}
//
Get whois and parse the domain name status
OK is not registered
Non-null Value Expiration Time
Null value Unknown
//
function GetInfo ()
{
/*
$dinfo = Trim ($this->getwhois ());
if ($dinfo = = "") return "";
if (eregi ("No Match", $dinfo)) return "OK";
return $rs;
*/
$WL = "";
$w _server = $this
toEXAMPLES: Using the exampleSee ALSO: Another referenceoperation after the man file is openedFlip Screen:Turn back one screen: Space(space bar)Flip One screen forward:b KeyTurn back one line: Enter(enter)Turn One line forward:K KeyFind:/keyword Backward Lookup? keyword forward lookupN: NextN: PreviousQ: ExitDate usesDate + "This is%Y. %n Today is%d "UTC Green Wedge Observatory time, Prime Meridian Greenwich Mean Time (old translation GMT or Greenwich Mean Time English: gmt prime Me
Some time ago, I spent a few nights working on an online tool site. New tools are not available recently. If you need any online tools, you can submit them,
I prefer to be a developer-related tool, and I am not interested in tools like online name checking.
Domain whois data mainly comes from a website that provides domain whois query, because the data queried by this site is more detailed than that of
HiChina whois, the interface used to provide valid interfaces for HiChina; Xinnet whois, non-Xinnet provided, just according to the new network's own website url modification to achieve EN "" http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">
PHP implements domain name whois query data source HiChina, xinnet_php_china Network Management Alliance bitsCN.c
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.