CodeIgniter,短UL不工作

时间:2015-09-25 14:56:41

标签: php .htaccess codeigniter

我可以访问http://myip/test/codeigniter/http://myip/test/codeigniter/index.php/内容。一个好点

但我无法访问以下网址:

http://myip/test/codeigniter/welcome

http://myip/test/codeigniter/welcome/index

http://myip/test/codeigniter/index.php/welcome

http://myip/test/codeigniter/index.php/welcome/index

在application / config / config.php

$config['index_page'] = '';

根目录上的.htaccess

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]  

<Files "index.php">
AcceptPathInfo On
</Files>

Apache已经很好地加载了rewrite_module

我错过了什么?

1 个答案:

答案 0 :(得分:0)

改变这个:

?

对此(注意RewriteRule ^(.*)$ index.php?/$1 [L] ):

{{1}}