I'm trying to figure out what I'm doing wrong with this .htaccess rewrite:
Options -Indexes
RewriteEngine on
RewriteBase /test/site/
RewriteOptions MaxRedirects=10
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /test/site/public/page.php?rel=$1 [NC,L,B]
I have an Front end script that handles all of the requests. In my case I don't need or have index.php/index.html file in my root project (/test/site/). That causes Apache to throw 403 error because of the first line of the code.
The code will work only if you access the links as follows:
http://localhost/test/site/public/index
http://localhost/test/site/public/something/else/index.html
But if you enter
http://localhost/test/site/public/
It'll throw 403 error.
I'm pretty sure I'm doing something wrong but I can't figure it out.
