文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>htaccess怪现象

htaccess怪现象

时间:2010-06-04  来源:luanqibazao

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,但不懂它为什么不转,却提示下载!这个有点意思,慢慢研究一下。
相关阅读 更多 +
排行榜 更多 +
辰域智控app

辰域智控app

系统工具 下载
网医联盟app

网医联盟app

运动健身 下载
汇丰汇选App

汇丰汇选App

金融理财 下载