CodeIgniter Forums

Full Version: How can I remove index.php part from URL
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]veledrom[/eluser]
Hi,

I have two controller classes (conta and contb) in my controller folder.

ht tp://localhost/ciserver/conta and ht tp://localhost/ciserver/contb won't work if I don't add index.php part, even if I have htaccess file or not.

Code:
$config['base_url'] = 'http://localhost/ciserver/';
$config['index_page'] = 'index.php';

$route['default_controller'] = "conta";


.htaccess
Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|web|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]