5

I am working with codeigniter framework, and as I upload it to a host, it gave me a 500 Internal error.

But when I add index.php to config.php , it worked.

What should I do?

In my .htaccess I have this:

RewriteEngine On

RewriteBase /ci-framework/

And also when I clean /ci-framework/ from end of RewriteBase it doesn't work.

Thank you very much.

2
  • 1
    make sure your wamp rewrite_modue is on.. in APACHE > APACHE Modules > rewrite_module Commented Jan 31, 2015 at 4:03
  • @HardikRanpariya I just cleaned RewriteBase /ci-framework/ and it works. Any way Thank you :) Commented Jan 31, 2015 at 8:55

1 Answer 1

8

You don't need to add index.php in config.php file. Make sure you have following line in .htaccess file:

<IfModule mod_rewrite.c>
  RewriteEngine On  
  RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>
Sign up to request clarification or add additional context in comments.

1 Comment

adding <IfModule mod_rewrite.c> in begining and closing with </IfModule> worked for me. :-)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.