How to truly redirect IIS website 301 (including homepage and inner page)

Source: Internet
Author: User

From: http://www.bnxb.com/host/win/200811/21-654.html
Generally, in IIS, the "redirect to URL" function takes effect only on the home page. 301 of the inner page is redirected to the home page.
After checking the data, we found that parameters still need to be added to the 301 redirection.

Reference content is as follows:

$ S transmits the suffix of the requested URL to the new URL. The suffix is the part reserved in the initial URL after it is replaced by a redirected URL.

If the exact_destination flag is not set, the name of the destination URL will have the name of the requested file (as the folder name) and the file name itself.

$ Q: Pass the parameters (such as querystring) in the initial URL to the new URL, including the question mark (?).

The specific operation is.

Open IIS. Create a website. Bind the meter to be switched. Such as my http://www.bnnb.cn/and right-click, properties, home directory.

Reference content is as follows:

Content of this resource comes from: select to redirect to URL (u)

Redirect to (c) enter my new domain http://www.bnxb.com $ S $ q/(note, I added the parameter $ S $ q)

Client redirection: select the correct URL (x) entered above and the permanent redirection of the resource (h)

And then confirm.

 

Test it. Enter http://www.bnnb.cn in the address bar/automatically jump to http://www.bnxb.com/

Try to jump to the internal page. Revenue http://www.bnnb.cn/win/13938.html automatically jumps to http://www.bnxb.com/win/13938.html

OK. The operation is successful.

 

For iis301 parameters, see: http://www.bnxb.com/host/win/200905/02-701.html

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.