. Htaccess File

Source: Internet
Author: User

In fact,. htaccess is not necessarily called. htaccess. You can use the Apache accessfilename command to change it to another name, such:

Accessfilename. config

 

The. htaccess file is a configuration file stored in a directory. It provides a specific configuration path for the directory. It uses the syntax format similar to that of the Apache configuration file.

 

In fact, it is not recommended. htaccess file, used only when necessary. however, it also provides a configuration method for users who have no permissions on the server. it is said that some VPs service providers use this method to provide services to users.

 

. Commands in htaccess can be implemented using the <directory> command and stored in the Apache configuration file. from a performance perspective, if AllowOverride is set to allow the use of AllowOverride, Apache will search in each directory. htaccess file, regardless of whether you use the file or not. in addition, the file must be loaded once every request. on the other hand, Apache also needs to search for the advanced directory. the htaccess file determines the instructions to be applied in the local directory. therefore, if the user requests a file under the/www/htdocs/example directory, Apache needs to search for the following directories:

 

/. Htaccess
/Www/. htaccess
/Www/htdocs/. htaccess
/Www/htdocs/example/. htaccess

 

From a security perspective, allowing users to modify server configurations may lead to unexpected changes.

You can use AllowOverride none to disable the. htaccess file.

 

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.