2
I’m using htaccess
to access the folders css
, js
, images
who are in /public
directly:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^(css|js|images)/(.*)$ public/$1/$2 [QSA,L]
</IfModule>
For example, when access is url http://localhost/css/file.css
it shows the content of http://localhost/public/css/file.css
But I want to deny access if the user type the "public" in the address, for example http://localhost/public/css/file.css
. It is possible to deny access if there is /public
at the address?
Thank you Daniel, I looked right now, actually the problem is different, when I try to access
http://localhost/css/file.css
error 403 appears too, which should only appear inhttp://localhost/public/css/file.css
– Guilherme Nascimento