apache下的htaccess用来控制访问权限,今天遇一怪现象,某同事在他的根下放了个.htaccess,内容包括:
RewriteEngine on
RewriteRule ^([0-9]+)$ /profiles/?u=$1 [L]
RewriteRule ^([0-9]+)/$ /profiles/?u=$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/server-status
RewriteCond %{REQUEST_URI} !=/server-info
RewriteCond %{REQUEST_METHOD} !^OPTIONS$
RewriteRule ^(.*)$ /index.php/$1 [L]
RewriteRule ^(services|job|advertise|ag|aquariumViewer|cinema|doubleclick|ea_admin|event|eyewonder|games|guilds|homes|internal|madadd|nda|newsroom|omg|popup|research|services|shindig|static|store|wap)/ 404.html
RewriteRule ^(buddylist.html|hotelfordogstest.html|launch.php|mallcoptest.html|reactivate.php|samp.html|test.php) 404.html
我们在测试代码时写了个test.php,内容就算phpinfo啦,htaccess没有把他转到404上去,浏览器却不断的提示下载test.php文件,虽然改了htaccess后,可以访问test.php,但不懂它为什么不转,却提示下载!这个有点意思,慢慢研究一下。
阅读(505) | 评论(0) | 转发(0) |