Jump to content

htaccess stop rewriting urls to specific directories


Noni
 Share

Recommended Posts

I have to admit i am not the best when it comes to htaccess configuration, so please help me solve the issue i am facing.

Invision board is not the only application on my domain. The forum is located in domain.com/forums directory

I have another app located in domain.com/app

The app is trying to access a page in domain.com/app/admin/index.php?controller=xml_feeds&action=manual_import&feed=somefeed

This page is redirecting always to the forum error page.

 

In the root domain, i have put the following htaccess file content but it's not working.
 

<IfModule mod_rewrite.c>
Options -MultiViews
RewriteEngine On
RewriteRule ^app - [L,NC]
RewriteRule ^app/admin/ - [L,NC]

RewriteBase /forums/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule \.(js|css|jpeg|jpg|gif|png|ico)(\?|$) /forums/404error.php [L,NC]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /forums/index.php [L]
</IfModule>
 

 

Link to comment
Share on other sites

atm try to put only this part in an htaccess in forums subdirectory and test if all works as expected:

<IfModule mod_rewrite.c>
 Options -MultiViews
 RewriteEngine On

RewriteBase /forums/
 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteRule \.(js|css|jpeg|jpg|gif|png|ico)(\?|$) /forums/404error.php [L,NC]

RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
 RewriteRule . /forums/index.php [L]
 </IfModule>

 

with this, instead:

RewriteRule ^app - [L,NC]
RewriteRule ^app/admin/ - [L,NC]

I don't have understand what is is scope.

Edited by laltroweb.it
Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...