AND attached files to this folder.
Answer 1, authority 100%
.htaccess file should be placed in the folder with files to be prohibited
& lt; FilesMatch ~ "\. (php | htm | html | js) $" & gt; Order allow, deny Deny from all & lt; / FilesMatch & gt;
Answer 2, authority 67%
One line in
Deny from all
Put the file in the folder to be closed. Everything in the folder will be closed.
Answer 3, authority 50%
To prevent browsing site directories, add the following code to .htaccess:
Options All -Indexes
Source – Habrahabr.