Apache rewrite module configuration enabling code Introduction

Source: Internet
Author: User

First, make sure that the conf/httpd. conf file in the Apache installation directory is Enabled:

# Code 1 # loadmodule rewrite_module modules/mod_rewrite.so

Then you need to specify the Directory and configuration for implementing the rewrite function in the httpd. conf file, as shown below:



# Code 2 # <directory "D: \ www \ BC"> # specify the directory where you want to execute the following rewrite rules # possible values for the options directive are "NONE ", "All", # or any combination: # indexes includes followsymlinks symlinksifownermatch execcgi Multiviews # note that "Multiviews" must be named * explicitly * --- "options all" # doesn't give it to you. # The options directive is both complicated and important. please see # http://httpd.apache.org/docs/2.2/mod/core.html#options # for more information. # options indexes followsymlinks # AllowOverride controls what directives may be placed in. htaccess files. # It Can Be "all", "NONE", or any combination of the keywords: # options fileinfo authconfig limit # AllowOverride all # the original value here is -- none by default, # controls who can get stuff from this server. # order allow, deny allow from all </directory>


This section introduces the configuration code above # Code 2 # the previous section:

DocumentRoot "D: \ www "# specify the root directory of APACHE service # Each directory to which Apache has access can be configured with respect # to which services and features are allowed and/or disabled in that # directory (and its subdirectories ). # first, we configure the "default" to be a very restrictive set of # features. # <directory/> # specify permissions for the Apache service root directory: AllowOverride | order deny, allow # deny from all options followsymlinks AllowOverride none order deny, allow deny from all </directory>


This article is from the "I am very dish" blog. I will not repost it!

Apache rewrite module configuration enabling code Introduction

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.