Is there an httpresponse header that redirects the user to some page of my site?

I am a server. The user sends me HTTP requests. I wonder if there is any HTTP response header that could use a high custom web browser for some /my/server/page.html

+6
source share
2 answers

You can use the Location header with a response code in the 3xx range .

Example:

 HTTP/1.1 302 Found Location: /my/server/page.html 
+9
source

301 and 302 HTTP codes can be used to redirect requests, for example:

 HTTP/1.1 302 Object moved Date: Fri, 28 Oct 2011 10:37:34 GMT Server: Microsoft-IIS/6.0 X-Powered-By: ASP.NET Location: http://www.xyz.com/abc 
+2
source

Source: https://habr.com/ru/post/900276/


All Articles