我在 ubuntu 12.10 上使用 apache2。但 htaccess 不工作,这是我的 htaccess 文件:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /ci/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php/$1 [L]
</IfModule>
<IfModule mod_security.c>
SecFilterEngine Off
SecFilterScanPOST Off
</IfModule>
$config['base_url'] = 'http://localhost/ci/index.php';
$config[‘index_page’] = “”;
$config[‘uri_protocol’] = “AUTO”;
1 http://localhost/ci/index.php/site/about
2 http://localhost/ci/site/about
第一个工作,但我希望第二个工作任何想法如何使它工作。谢谢
404 Not Found
The requested URL /ci/site/about was not found on this server.