internetservice_dk
asked on
mod_rewrite - strange output
On a site using mod_rewrite I'm experiencing some strange output.
The main site are using the .htaccess file below, to rewrite url's - works fine...
But the subfolder /admin seems to inherit the rewrite behaviour even though this is not wanted - how can I stop this ?
RewriteEngine on
RewriteBase /
# Directories to ignore
RewriteRule ^(assets|inc|cms|css|image s|img|admi n|js|topim ages|video )(/.*)?$ - [L]
RewriteRule ^(index\.php)$ - [L]
RewriteRule ^(mod_redirect\.php) - [L]
RewriteRule ^(balule_mail\.php) - [L]
RewriteRule ^(login\.php) - [L]
RewriteRule ^(.*)(\.html)$ mod_redirect.php?url=$1$2 [L]
RewriteRule ^([^/]*)/([^/]*)/?$ index.php?lang=$1&url=$2 [NC]
RewriteRule ^([^/]*)/?$ index.php?url=$1 [NC]
In /admin I have a file "login.php" - and it seems like every time I request that file, the server also streams the index file from the main site ?!?
So basicly, I'm looking for a way to stop the inheritance from the parent folders .htaccess file, is that even possible ??
Best regards,
Mark
The main site are using the .htaccess file below, to rewrite url's - works fine...
But the subfolder /admin seems to inherit the rewrite behaviour even though this is not wanted - how can I stop this ?
RewriteEngine on
RewriteBase /
# Directories to ignore
RewriteRule ^(assets|inc|cms|css|image
RewriteRule ^(index\.php)$ - [L]
RewriteRule ^(mod_redirect\.php) - [L]
RewriteRule ^(balule_mail\.php) - [L]
RewriteRule ^(login\.php) - [L]
RewriteRule ^(.*)(\.html)$ mod_redirect.php?url=$1$2 [L]
RewriteRule ^([^/]*)/([^/]*)/?$ index.php?lang=$1&url=$2 [NC]
RewriteRule ^([^/]*)/?$ index.php?url=$1 [NC]
In /admin I have a file "login.php" - and it seems like every time I request that file, the server also streams the index file from the main site ?!?
So basicly, I'm looking for a way to stop the inheritance from the parent folders .htaccess file, is that even possible ??
Best regards,
Mark
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Right to the point :)
RewriteEngine off