Writing pseudo-static rules in windows and linux

Source: Internet
Author: User
Writing pseudo-static rules in windows and linux

  1. [Isapi_rewrite] # enable disguised static rules
  2. Rewriterule/(%0-9%%%%.html/contents. php? W = $1 [I]

Any address starting with a number is transferred to contents. php? W = $1 this $1 represents the content received by the previous ([0-9] +), followedIs case insensitive.

How to use letters:

  1. Rewriterule/(%a-z%%%%%.html/contents. php? W = $1 [I]

You only need to change the number to the letter range you need.

How to represent all characters:

  1. Rewriterule/tag _ (. * example .html/search. php? S = $1 [I]

2. linux pseudo-static file names are:. htaccess rules:

  1. Rewriteengine on # enable disguised static rules
  2. Rewriterule (%0-9%%%%%.html $/contents. php? W = $1 [l, nc]

Any address starting with a number is transferred to contents. php? W = $1 this $1 represents the content received in the front ([0-9] +), and the [l, nc] in the back indicates that the content is case insensitive.

The letter representation is the same as that for windows

How to represent all characters:

  1. Rewriterule tag _ (. * developer.html $/search. php? S = $1 [l, nc]

Through the above method, I believe you already know how to use pseudo-static rules. you only need to place the above files in the space root directory. the above method, as long as space support, any language, asp ,. net, php, and jsp can all be used. the pseudo-static state can make the page url look fresh. as for seo, I don't know whether it works.

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.