Like a lot of web developers, I like to use .htaccess to direct all traffic to a domain through a single point of entry when the request isn't for a file that exists in the publicly served directory.
So something like this:
RewriteEngine On
# enable symbolic links
Options +FollowSymLinks
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.+) index.php [L]
This means if the request isn't for a css file or an image, my index.php gets the request and I can choose what to do (serve up some content or perhaps a 404)
Works great, but I've stumbled upon an issue it can't seem to help me solve.
My document root looks like this:
asymboliclink -> /somewhere/else
css
.htaccess
img
includes
index.php
Yet, Apache doesn't see the symbolic link to a directory as a directory. It passes the request on to my index.php in the root. I want to serve the link as if it were a folder as it is a link to a folder with it's own index.php. I can access http://example.com/asymboliclink/index.php by typing it in the address bar of a browser, but I want to be able to access it through http://example.com/asymboliclink
What do I need to add to my .htaccess file to make this happen?