1, simplify the code. (in fact, the definition of a few variables is removed)
2, for the information retrieved from InterNIC is too simple, according to InterNIC feedback information in the WHOIS server for further inquiries. For example, Yahoo has more detailed information on the whois.networksolutions.com.
Class Whois {
var $use _cache = 1;
var $FROM _cache=0;
var $cache _dir = "./"; Set yourself accordin
Use PHP to query the domain name status whois class. Copy the code as follows :? ClassSearchDomain {var $ domain; functionSetDomain ($ udomain) {$ this-domain $ udomain;} get whois and analyze the domain name status. OK is not registered. it is not empty.
The code is as follows:
Class SearchDomain{Var $ domain = "";Function SetDomain ($ udomain){$ This-> domain = $ udomain;}//// Obtain
Php queries whois information, and phpwhois information. Methods for querying whois information in php. phpwhois information in this document describes how to query whois information in php. Share it with you for your reference. The details are as follows: Here we use php to query the whois information through php, and
1, simplify the code. (in fact, the definition of a few variables is removed)
2, for the information retrieved from InterNIC is too simple, according to InterNIC feedback information in the WHOIS server for further inquiries. For example, Yahoo has more detailed information on the whois.networksolutions.com.
Class Whois {
var $use _cache = 1;
var $FROM _cache=0;
var $cache _dir = "./"; Set yourself accord
I. Classification of information collection
The methods of information collection can be grouped into two categories:
1. Active Collection: Active collection is to obtain relevant information, such as ICMP ping or TCP port scan, by directly initiating interaction with the target network being tested.
2. Passive collection: Passive collection is through Third-party services to obtain information on the target network, such as the use of Google search engine.
second, the domain name information
1, simplified the code. (It actually removes some of the variables that you don't need to define)
2, for the information retrieved from the InterNIC is too simple, according to InterNIC feedback in the information of WHOIS server for further inquiries. Yahoo, for example, has more detailed information on the whois.networksolutions.com.
Class Whois {
var $use _cache = 1;
var $FROM _cache=0;
var $cache _dir
1. simplified the code. (In fact, some unnecessary variable definitions are removed)2. The information retrieved from INTERNIC is too simple. Further query is performed based on the whois server in INTERNIC feedback. For example, YAHOO has more detailed information on whois.networksolutions.com.Class whois {Var $ use_cache = 1;Var $ FROM_CACHE = 0;Var $ cache_dir = "./"; // according to your system settings
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
Idea: first tidy up all the domain name after the WHOIS host address, put him into the XML package into the app, check the domain name to get this XML corresponding host address, and then connect to this address with the socket, send/Receive information (this XML file under assets).First on:(This whois.xml is what I did ten years ago, and I've spent a lot of time collecting most of the reliable Whois hosts,
Here we obtain data from the data interface of the WAN or new network, and then output it through the simple text processing of PHP.
Copy Code code as follows:
$domain = $_get[' Q '];
Preg_match ("|
|is ", @file_get_contents (' http://www.xinnet.cn/Modules/agent/serv/pages/domain_whois.jsp?domainNameWhois= '. $ Domain. ' nocode=nocode '), $whois);
echo $whois [1];
?>
Do here,
I have been searching for APIs in PHP for WHOIS (with PHP example) for a long time.
Reply to discussion (solution)
Disguised advertisements for junk/junk charges
The best way is to connect to the official whois server. you call your own There are too many things in php whois.
Obviously, you can add your website traffic and directly obtain the offic
using python for whois queries
installing whois with the PIP command
Pip Install Python-whois
Python 2.7.6 (default, OCT 2016, 20:30:19)
[GCC 4.8.4] on linux2
Type ' help ', ' copyright ', ' credits ' or ' Licens E "For more information.
" >>> import whois
>>>
How to use the installation successfully
[GCC 4.8.4] on
Whois is simply a database that queries whether the domain name has been registered, as well as the details of the registered domain name (such as domain name owner, domain name registrar, domain name registration date, and expiration date, etc.). Through the domain name WHOIS server query, you can query the contact information of the domain owner, as well as the registration and expiration time. In general
Due to the historical reasons for the Internet, Apin is responsible for the overall network IP planning as well as the North American region also has some of Africa's IP allocation management, and accordingly, whois.apin.net is the IP whois root server, the standard IP whois query method is , first query the whois.apin.net for which area an IP belongs to, and then query the
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.