4
I created a directory assets
in order to place the Assets of my project.
So far so good, however, I found that when typing in the URL localhost/project/assets
, it shows the directory structure of that folder. In order to prevent this action, I created a file .htaccess
in the directory assets
:
Deny from all
Create the .htaccess
as above prevented the view of the directory, but caused an error: no file being CSS or Javascript is loaded from this folder.
So my question is:
There is a way to hide only the directories, leaving visible and their respective files for my own application?
Thank you very much, Leonardo! It worked perfectly. ^-^
– Luiz Felipe
Not at all. You can click the tick ("v") below the answer and it will be marked as accepted. Thus, it is documented to others who come to access the site that the answer has solved your problem.
– Leonardo Pessoa