Enabling Mod Rewrite in Xampp
Filed Under: Blogging, Software, WordPress
As the final release of WordPress 2.5 fast approaches, I’ve been having a lot of fun playing around with 2.4-bleeding which has since become WP 2.5 Beta. Since the changes have been coming fast and furious these last few weeks I’m sure glad I use a Subversion client to connect to the WordPress Subversion Repository - it provides for a much simpler and faster method for keeping up to date. Running WordPress in a local environment I prefer to use Xampp, a robust open-source application that will install Apache webserver and MySQL database on your PC with complete access via phpMyAdmin.
Although Xampp is my favourite method of running WordPress locally, there was always a minor little detail that irritated me to no end. In order to use fancy permalinks you of course need mod_rewrite (an Apache module that rewrites permalinks on the fly) enabled otherwise you end up with index.php in all of your permalinks. I hated this. Naturally mod_rewrite is disabled by default. Despite my best efforts in trying to figure out how to enable mod_rewrite in Xampp I failed miserably. I searched the Apache Friends web site with no success. I searched the Xampp Forums, half of which is in German, but came up with nothing. Undaunted I decided to take matters into my own hands and go through the installation files rather meticulously. My labours were rewarded.
For those of you running Xampp 1.6.6a on Windows and unable to figure out how to enable mod_rewrite the fix is simple. Assuming you have installed Xampp in root (which you should) navigate to,
C:\xampp\apache\conf\httpd.conf
Open up httpd.conf in notepad and look for this line.
#LoadModule rewrite_module modules/mod_rewrite.so
Uncomment it so that it reads,
LoadModule rewrite_module modules/mod_rewrite.so
Next, search for AllowOverride None and change it to AllowOverride All. Once you restart Apache you will be able to enable fancy permalinks without the index.php appendage.
Thanks for visiting! If this is your first time here why not grab the RSS feed. You can also follow this discussion by checking the "Notify me of followup comments via e-mail" box or by subscribing to the comments RSS feed. Please scroll down to leave your comment.




4 Comments so far. Add Yours Now!
Ted
Thank you. It worked just as you described.
Jun 30th, 2008
Len Kutchma
You’re welcome Ted.
Jun 30th, 2008
neekey
Thank you for your tip!
Aug 16th, 2008
Len Kutchma
You’re welcome Neekey.
Aug 17th, 2008
Reply to “Enabling Mod Rewrite in Xampp”
Please note: Comment moderation is in effect. It may take some time for your comment to appear. There is no need to resubmit it.
Management does not necessarily endorse or agree with comments left here. Management reserves the right to not publish comments it deems unfit. Play nice.