I have a folder App\ressources that contains all the images, javascript library of the website.
What i’m trying to do is to redirect to the existing image/js or go to the index.php file that will handle the request and get the current module/controller/action.
So i made this :
RewriteEngine On
RewriteCond App/ressources/$1 -d [OR]
RewriteCond App/ressources/$1 -f
RewriteRule ^(.+)$ App/ressources/$1 [L]
RewriteRule ^(.*)$ index.php [QSA]
It shoud not be difficult but “debuging” is not possible.
I’ve asked for same question but i didn’t get an answer.
Here is my workaround:
Basically we redirect everything (what doesn’t exists as file) to App/ressources and if it still doesn’t exist we redirect it back to / root dir. Then we redirect it to index.php.