CodeIgniter Escaping Clean URLs adding index.php/
I've setup clean URLs on CodeIgniter through .htaccess and they work fine. Sometimes though CI seems to esc开发者_JAVA技巧ape it's clean urls and go back to index.php/ urls. So far I've tracked it down to either:
- Forms
- Redirects
If you are using mod_rewrite
to remove index.php
from url. You need to change in config
file also to make in redirect or from, urls aren't using index.php
. You need change in config.php
from $config['index_page'] = "index.php"; to $config['index_page'] = "";
.
Please check the comments in config files above that line :)
On line 29, in config.php file:
$config['index_page'] = 'index.php';
remove the index.php, so it looks like:
$config['index_page'] = '';
精彩评论