If you are just beginning to learn PHP, there may be many functions to study, today we will learn how to use the PHP Header (), more instructions, please refer to the PHP Chinese manual, the following is about the Header function detailed use
Header () in PHP &html–refresh (Redirect) to location (URL) in X seconds,headerinphp
Case 1:redirect a page to a URL without waiting in PHP.
1
header("Location: index.php");
Case 2:redirect a page to the URL after waiting
Yii Notes---Redirect redirect, Yii---redirect
The redirect method of Yii is defined in both Ccontroler and CHttpRequest, and redirect in Ccontroller is called CHttpRequest method in redirect. What we normally call is the redirect method in
Permanent page removal (301 redirects ) is a very important "auto-steering" technology. One of the most feasible ways to redirect URLs. When a user or a search engine makes a browse request to the Web server, one of the status codes in the header
Case 1:redirect a page to a URL without waiting in PHP.
1
header("Location: index.php");
Case 2:redirect a page to the URL after waiting for X seconds in PHP.
12345
header("Refresh: 5; url=index.php")
Header () in PHP & html-Refresh (Redirect) to Location (URL) in X seconds, headerinphpCase 1: Redirect a page to a URL without waiting in PHP.
1
header("Location: index.php");
Case 2: Redirect a page to an URL after waiting for X
Yii Notes---redirect redirection
The redirect method of Yii is defined in both Ccontroler and CHttpRequest, and redirect in Ccontroller is called CHttpRequest method in redirect. What we normally call is the redirect method in
: This article mainly introduces Header () inPHP & html-Refresh (Redirect) toLocation (URL) inXseconds. if you are interested in the PHP Tutorial, refer to it. Case 1: Redirect a page to a URL without waiting in PHP.
1
header("Location:
What is header information?Here is only a simple explanation, detailed look at the HTTP protocol.In the HTTP protocol, the server-side answer (response) consists of two parts: header information (headers) and body content, where the header
One, what is 301 redirect301 Redirect (or call 301 jump, 301 turn) is a user or search engine spider to the site server to make access requests, the service returns the HTTP data stream header part of the status code of one, indicating that this
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.