在Kohana
有一个在.htaccess
Kohana的模块-files
# Protect application and system files from being viewed
RewriteRule ^(?:application|modules|system)\b.* index.php/$0 [L]
modules
-path保护我怎么能允许像路径:
http://localhost/modules/mymodule/media/js/myjavascript.js
我想包括JavaScript和其他媒体文件到我的模块,并仍然保护其他模块文件,如.php
我可以允许整个modules
-path,但是所有的.php
文件也会被列出。
# Protect application and system files from being viewed
RewriteRule ^(?:application|system)\b.* index.php/$0 [L]
肯定有基本的PHP - 保护,但我还是不希望任何人都可以列出我modules
-path。
<?php defined('SYSPATH') or die('No direct script access.');