0

Possible Duplicate:
how to remove index.php from url in codeigniter ?

I want to remove index.php from the codeigniter url. I have created .htaccess file and placed the following code on it (as found on the CodeIgniter website. But i can not access anything on the localhost. I get the error "Not Found", if i place the code in the .htaccessfile.

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

My url looks like localhost/test/project/index.php

Community
  • 1
  • 1
Roman
  • 3,724
  • 21
  • 50
  • 70

3 Answers3

1

did you remove index.php like so

$config['index_page'] = '';

from the config file in your config folder from application ?

Toddbt
  • 31
  • 3
0
Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*)$ index.php
Sujit Agarwal
  • 11,994
  • 11
  • 45
  • 78
0

If you have tried everything in the user guide and had no luck it may be an issue with your local setup. If you are on a Mac there may be an issue with your Apache setup. I would check /etc/apache2/[username].conf and make sure that you have AllowOverride set to All.

ib.
  • 26,410
  • 10
  • 77
  • 98