I want to use mod-rewrite to check a file in two different places: at the requested URL and at the requested URL in the โpublicโ directory.
Here is what I still have:
RewriteCond% {REQUEST_FILENAME}! -F
RewriteCond% {REQUEST_FILENAME}! -D
RewriteCond% {DOCUMENT_ROOT} / public / $ 0! -F #this line isn't working
RewriteRule ^ (. *) $ Index.php? $ 1 [L]
It can correctly determine if there is a file, but it does not correctly determine if the file is in /public/supplied/file/path/file.extension. How can I check this?
source
share