• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Site is not running due to redirect mode of codeigniter


i m working on a codeigniter and my site is not working without writing index.php with URL and also it only shows default controller with index.php and it didn't run any other controller with OR without index.php

e.g. www.mysitename.com/index.php it show default controller
www.mysitename.com it show me the 404 page of codeigniter.
www.mysitename.com/anycontroller it show me the 404 page of codeigniter.
www.mysitename.com/index.php/mycontroller it show me the 404 page of codeigniter.

please help me out.

Thanks in Advanvce

Usman Abdul Razzaq

Have you setup a .htaccess file correctly? http://ellislab.com/codeigniter/user-gui.../urls.html


i have setup htaccess correctly same as

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

but its not making any difference in this situation.

Please help

Thanks In advance

Usman Abdul Razzaq

Options FollowSymLinks
RewriteEngine on

# Everything else to the CI controller
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
What have you got in the config.php file for index_page etc.?


$config['index_page'] = "";

config.php file for index_page.

Change it back to index.php and remove the .htaccess - does it all work correctly again?

Thanks So much got the solution.

Thanks again for so much help

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.