htaccess

Most web developers use a “third party” web server which comes in a package such as WAMP or XAMPP resulting to miss configuration of the web server to perform several capabilities.  One of which is allowing htaccess configuration to take over the webserver’s main configuration.  Even apache itself usage of htaccess is disabled by default and configuring the server is needed to allow htaccess on your server.  Below is how to allow htaccess on your web server:

Open your Apache httpd.conf Configuration File and “uncomment” the line

#LoadModule rewrite_module modules/mod_rewrite.so

You can “uncomment” it by removing the number sign “#” resulting to

LoadModule rewrite_module modules/mod_rewrite.so

After removing the number sign you need to change the AllowOverride directive, the default configuration is:

</Directory>
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Satisfy all
</Directory>

It should be changed to :

<Directory />
Options FollowSymLinks
AllowOverride All
Order deny,allow
Deny from all
Satisfy all
</Directory>

You also need to change the line

AllowOverride None

to

AllowOverride All

this can be found where you set your DocumentRoot where in my case is set to (</Directory “D:/HTDOCS”>).  After configuring Apache you need to restart the server for the changes to take effect.

Did find the post very useful? Maybe you want to buy me a glass of beer!