Apache error log: Invalid command ‘RewriteEngine’
After adding the “RewriteEngine on” on an .htaccess file, I got the following error in apache’s error.log:
.htaccess: Invalid command 'RewriteEngine', perhaps misspelled or defined by a module not included in the server configuration
To fix it, I’ve added the rewrite module to apache:
$ sudo a2enmod rewrite $ sudo /etc/init.d/apache2 restart
Categories: apache
a2enmod, htaccess, RewriteEngine
how we do this if we are using windows server? surely i cant do sudo in windows 2008
LikeLike
Have a look at this post https://tomelliott.com/php/mod_rewrite-windows-apache-url-rewriting
LikeLike
There is no rewrite mod in the box. What to do ?
LikeLike
Hi @jkeks, take a look at this post: http://sharadchhetri.com/2014/02/21/error-module-rewrite-exist/
Maybe it’s your same problem.
LikeLike
Thankyou very much!
LikeLike
Thank you!
LikeLike
It works. Thanks for ur help…. 🙂
LikeLike