I'm hoping someone can give me a suggestion on how to fix this. I've developed a codeigniter app and just uploaded it to a godaddy subdomain. It was working perfectly locally, however when running it at ci.site.com
, all urls are being routed to the default controller. For instance, say my default controller is set to $route['default_controller'] = 'home/index';
. If I go to ci.site.com
, the home controller loads the index method just fine, however when going to ci.site.com/users/index
, I'm routed back to home/index
even though the url reads ci.site.com/users/index
.
This is what my /.htaccess
looks like, the CI app and .htaccess
are in document root :
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]
RewriteCond %{REQUEST_URI} ^application.*
RewriteRule ^(.*)$ /index.php?/$1 [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>
<IfModule !mod_rewrite.c>
ErrorDocument 404 /index.php
</IfModule>
I've deployed several CI apps and have never run into this problem. Both my base_url
and index_page
config parameters are correct, I just can't seem to figure it out. Any suggestions would be much appreciated.