我有这种情况:htaccess的保护所有子文件夹和文件
/storage
index.php
other scripts.php
/files
-files and folders-
我想拒绝所有的HTTP请求中的所有文件和/files
子文件夹,但同时允许访问/storage
和运行的PHP脚本。我尝试了一些规则,但它们或者只保护文件列表,或者不允许访问所有/storage
文件夹。
该.htaccess
必须在/files
之外(因为此文件夹访问PHP readfile
和.htaccess
可能是可访问的)。
我收到500个错误 – 2011-06-06 00:03:35
我的歉意,我已经添加了更新。 – preinheimer 2011-06-06 00:14:15