views:

18

answers:

1

I have a CodeIgniter site and the problem is I have:

RewriteCond %{HTTP_HOST} ^example\.com
RewriteRule ^(.*)$ http://www.example.com/$1 [R=permanent,L]

But this results in people going from example.com to www.example.com/index.php/

I'd like them simply to go to www.example.com

Any ideas? Also, if they're at example.com/page1 they should go to www.example.com/page1

Thanks

+1  A: 

Apache is rewriting / to /index.php/ before that rule is processed. Try moving it to the top of the file.

icktoofay