I'm having problems with rewrite rules that should only be applied to subfolders in a specific folder...
i've got my site at http://localhost/installdir/
When I put following rules in a .htaccess in the /install/ dir everything works perfectly
- Code: Select all
#mod rewrite
RewriteEngine On
Options +FollowSymlinks
#site is at http://localhost/installdir/
RewriteBase /installdir/
#do not rewrite on the foo dir
RewriteCond %{REQUEST_URI} !^/installdir/foo/
#rewrite everything in the document folder to the rewrite download script
RewriteRule ^storage/([^/]+)/document/(.*)$ /installdir/foo/document/rewrite_dl.php?doc_url=/$2&storageDir=$1
This way files are streamed by a php script that checks if the user has the right to download the file.
I'd like to move the .htaccess into /installdir/storage/
The moment I do this rewriting fails
What should I change?
Thanks!
B.