Options -Indexes
#
# RewriteEngine on
# RewriteCond %{REQUEST_URI} !^public
# RewriteRule ^(.*)$ frontend/web/$1 [L]
#
RewriteEngine on
RewriteCond %{REQUEST_URI} !^/backend/web/(assets|css)/
RewriteCond %{REQUEST_URI} admin
RewriteRule .* backend/web/index.php [L]
RewriteCond %{REQUEST_URI} !^/(frontend|backend)/web/(assets|css|img)/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} !admin
RewriteRule .* frontend/web/index.php [L]
# Deny accessing below extensions
Order allow,deny
Deny from all
# Deny accessing dot files
RewriteRule (^\.|/\.) - [F]