CodingForums.com

CodingForums.com (http://www.codingforums.com/index.php)
-   Apache configuration (http://www.codingforums.com/forumdisplay.php?f=69)
-   -   htaccess in root conflicts with that of wordpress (http://www.codingforums.com/showthread.php?t=146448)

abduraooft 08-12-2008 09:09 AM

htaccess in root conflicts with that of wordpress
 
Hi all,

I've an htaccess in root like
Code:

RewriteEngine On

Options -Indexes
Options +FollowSymlinks

RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?page=$1 [L]

to handle all requests in index.php of root directory.

There is a wordpress module inside the /events directory, which has another htaccess like
Code:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /events/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /events/index.php [L]
</IfModule>

# END WordPress

Everything is fine if I make requests like http://www.example.com/events/ (with a trailing slash), but I get 500 Error - Internal Server Error when I try to access the page like http://www.example.com/events (with no slash at the end)

What could be the reason? Can I write another rule to tell the system to consider /events like /events/?

Any help would be highly appreciated.

Edit: I removed the forced www rule for the time being :cool:


All times are GMT +1. The time now is 07:37 PM.

Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.