PHP Get root domain method Summary, PHP get domain name summary
This article summarizes the PHP get root domain name method, share to everyone for your reference. The implementation method is as follows:
If you simply get the current access to your
This article describes how PHP can obtain parameters such as the current host, domain name, URL, path, and port, if you are interested, please refer to this article. This article describes how PHP can obtain parameters such as the current host,
The synchronous login requirement must meet the following three key points:1) users logging on to domain A can perform synchronous login when they jump to domain B;2) click the exit link under domain A under domain B to exit both domain A and domain
Global array
echo $_server["Http_host"];
The bbs.it-home.org will be output.
Copy CodeLocal tests will output localhost.Method 2, using the Parse_url function;
";p Rint_r ($arr); echo"";? >The output is an array with
echo server[' server_name '];//get the source URL, that is, click to the previous page of this page URL
echo server["Http_referer"];
server[' Request_uri '];//gets the suffix of the current domain name
server[' Http_host '];//get
Php obtains the summary of root domain names. Php obtains the root domain name summary. if you only get the domain name currently accessing your page, you only need to use the HTTP_HOST function in php, if the root domain name of the extracted url
Yii method for obtaining the current url and domain name. Yii: how to get the current url and domain name this article describes how Yii gets the current url and domain name. Share it with you for your reference. Details: assume that the access
Php+ajax Domain Name Query preparation knowledge
This query system uses the Ajax function of PHP and JQUery to realize the query of domain name information (this is the main implementation of the domain name has been registered query). The system
Yii method to get the current URL and domain name
The examples in this article describe how Yii obtains the current URL and domain name. Share to everyone for your reference. Specific as follows:
Suppose our current page access address is:
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.