【发布时间】:2018-01-27 22:33:53
【问题描述】:
我正在 Kali Linux 中使用 Code Igniter,我已经按照文档中的说明配置了 .htaccess 文件并正确配置了文件,但是如果没有 index.php,它就无法工作
a2enmod rewrite
我还启用了重写模式并重新启动了 apache。这是我的 .htaccess 文件
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
【问题讨论】:
-
你在 $config['index_page'] 的 config.php 中删除了“index.php”吗?
-
like $config['index_page'] = "";
-
@Gopalakrishnan 是的,我做到了,但仍然是同样的问题!
-
下面的答案肯定对你有帮助。如果不检查其他代码
标签: php apache .htaccess codeigniter url