Forum Moderators: phranque
RewriteCond %{REQUEST_URI} !.*\.(ico|gif|jpg|jpeg|png|js|css)
RewriteCond %{REQUEST_URI} ^/backend(/.*)?$
RewriteRule backend/.* backend/index.php
SSLRequireSSL
...
any request being made on HTTP is redirected to HTTPS
if you change nothing else, put those server-intensive !f and !d tests after the filename tests. And why all the separate rules? That's what the $1 capture is for.
# BACKEND/CUSTOMER/API APPS
RewriteCond %{REQUEST_URI} !\.(ico|gif|jpg|jpeg|png|js|css)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(backend|customer|api)/ $1/index.php [L] # FRONTEND APP
RewriteCond %{REQUEST_URI} !\.(ico|gif|jpg|jpeg|png|js|css)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php[L]
RewriteRule ^(backend|customer|api)/ $1/index.php [L]