Jump to content


This topic is now archived and is closed to further replies.


How to enable mod_rewrite in Apache 2.0.54 ?

Recommended Posts

A pre-written PHP Application require me to enable mod_rewrite to be enabled in my Apache web server.


I have Apache 2.0.54 installed on my PC.

I checked the module directory in my Apache instalation directory, and I found a filemod_rewrite.so, and I thought I gave mod_rewrite in my Apache, just have to enable it.

I opened httpd.conf and removed the # from the front of following line.


[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]LoadModule rewrite_module modules/mod_rewrite.so


restarted my Apache, but it is still not working.

some body tell me how to do it,

how to enable mod_rewrite ?

Share this post

Link to post
Share on other sites

somewhere in your apache conf file you need to add the line


AddModule mod_rewite.c


however I'm not sure exactly WHERE it is supposed to go.


I'm going to keep looking but I'll check back here and see if anyone has posted a pointer in the mean time

Share this post

Link to post
Share on other sites

This has been a while now.

I am still looking for an answer with this issue.


I have added the line


AddModule mod_rewrite.c


on the line below


LoadModule rewrite_module modules/mod_rewrite.so


but everytime I uncomment it and try to restart Apache it fails as soon as I comment it out Apache will restart with out problems.


I have check via phpinfo.php and the rewrite module is not showing up.


I have direct access to my server (no uploading/ftp or anything) and I have direct access to the conf file.


thanks in advance kia

Share this post

Link to post
Share on other sites

I am also having the same problem in Apache 2.0.54 version.

If I place "AddModule mod_rewite.c" then Apache not starting.


Please help on this








Share this post

Link to post
Share on other sites

I did experience the same problem when adding the AddModule mod_rewite.c line into httpd.conf (NOT removing the comment - because the original httpd.conf does not have this line). And apache won't start. But as they say mod_rewrite is already included in the conf file of apache, all you have to do is to uncomment sth, so I dont think the line AddModule mod_rewite.c is necessary. So the problem with mod_write not working (when you've uncommented LoadModule rewrite_module modules/mod_rewrite.so) lies somewhere else: if you've changed the path of document root (i.e. the one you arrive at by entering [a href=\"http://localhost\" target=\"_blank\"]http://localhost[/a] ), you should have changed the line DocumentRoot "C:/Program Files/xampp/htdocs", for example, to another path, and it should works fine. But for mod_rewrite to work properly (and maybe for other things as well), however, you must change another line, that is , e.g. <Directory "C:/Program Files/xampp/htdocs">, to reflect the new path to the document root. Change that and you should be done with mod_rewrite!

Share this post

Link to post
Share on other sites


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.