Rewrite Rules not working

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Rewrite Rules not working

Postby magicmarkuk » 29. April 2012 09:20

Hello

I am having problems with ReWrite rules not working. Everytime I click a link that has a rewrite rule attached I get a 404 error.

The .htaccess file is as follows:

Code: Select all
options -multiviews
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^users$ users.php
RewriteRule ^login$ login.php
RewriteRule ^logout$ logout.php
RewriteRule ^signup$ signup.php
RewriteRule ^forgotpassword$ forgotpassword.php
RewriteRule ^feature$ feature.php
RewriteRule ^feature_success$ feature_success.php
RewriteRule ^purchases$ purchases.php
RewriteRule ^categories/([^/.]+)?$ cat.php?cid=$1&%{QUERY_STRING}
RewriteRule ^user/([^/.]+)?$ user.php?uname=$1&%{QUERY_STRING}
RewriteRule ^tags/([^/.]+)/([^/.]+)?$ tags.php?cid=$1&tag=$2&%{QUERY_STRING}
RewriteRule ^([^/.]+)/([^/.]+)/([^/.]*)?$ view.php?title=$1&id=$2&%{QUERY_STRING}
</IfModule>
<IfModule mod_security.c>
   # Turn off mod_security filtering.
   SecFilterEngine Off

   # The below probably isn't needed,
   # but better safe than sorry.
   SecFilterScanPOST Off
</IfModule>


I have checked the httpd.conf file and this has the following line not commented out:

Code: Select all
LoadModule rewrite_module modules/mod_rewrite.so


Can anyone suggest what else could be causing the problem please?

Many thanks
Mark
magicmarkuk
 
Posts: 1
Joined: 29. April 2012 09:14
Operating System: Windows 7

Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 109 guests