Apache出于某种原因重定向URL
为什么apache会像Apache出于某种原因重定向URL,apache,.htaccess,redirect,Apache,.htaccess,Redirect,为什么apache会像http://localhost/~user/test至http://localhost/~user/test.php?我怎样才能关掉这个?我对此和.htaccess有问题,因为 RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php 不会重定向http://localhost/~user/test到
http://localhost/~user/test
至http://localhost/~user/test.php
?我怎样才能关掉这个?我对此和.htaccess
有问题,因为
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php
不会重定向http://localhost/~user/test
到index.php
,但改为test.php
(我想它会将URL视为一个文件)
详情:
httpd -v
Server version: Apache/2.2.21 (Unix)
sw_vers
ProductName: Mac OS X
ProductVersion: 10.7.3
BuildVersion: 11D50d
将选项-多视图添加到htaccess