Apache服务器
config文件配置是这样的
'URL_HTML_SUFFIX'=>'html',
'URL_CASE_INSENSITIVE' => true,
'URL_MODEL' => 2,
'URL_ROUTER_ON' =>true,
.htaccess文件配置是这样的
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{REQUEST_METHOD} ^TRACE
RewriteRule .* - [F]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]
RewriteCond %{HTTP_HOST} ^xxx.cn [NC]
RewriteRule ^(.*)$ http://www.xxx.cn/$1 [L,R=301]
问题是这样的:
目前通过xxx.cn可以正常跳转到www.xxx.cn,其他非首页链接跳转后会增加index.php,已测试没有这个index.php也是可以正常访问的,做了隐藏的,但是
比如xxx.cn/home/test/test/这样的非首页链接,跳转就会变成www.xxx.cn/index.php/home/test/test/
为什么会多了index.php?如何去掉这个index.php?