0

I have AllowOverride All in /etc/apache2/sites-available/default.

I added .htaccess with the following code.

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

Without this htaccess, I am able to see the web page. but after adding this I am not able to see it. I get the following error.

Could anyone tell me how to fix the problem?

Thanks in advance.

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, webmaster@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log. Apache/2.2.14 (Ubuntu) Server at localhost Port 80

2
  • 1
    Is the mod_rewrite module loaded? Do you have a /etc/apache2/mods-enabled/rewrite.load symlink?
    – andol
    Aug 8, 2010 at 20:16
  • 1
    Did you look in the error log?
    – freiheit
    Aug 8, 2010 at 20:36

1 Answer 1

0

What's $1 in the REQUEST_COND? Shouldn't it be REQUEST_FILENAME?

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

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .