mod_rewrite is a useful Apache module that allows you to easily redirect and rewrite URLs. If you run Apache web server using XAMPP/WAMP then here are the steps to enable mod_rewrite in XAMPP, WAMP.
How To Enable mod_rewrite in XAMPP, WAMP
Here are the steps enable mod_rewrite in XAMPP, WAMP.
1. Open httpd.conf
Open the Apache configuration file httpd.conf in a text editor. You will find this file in one of the following locations depending on whether you use XAMPP or WAMP.
Also read : How to Change Default Index Page in Apache
2. Enable mod_rewrite
Look for the following line
#LoadModule rewrite_module modules/mod_rewrite.so
Uncomment it by removing # at its beginning.
LoadModule rewrite_module modules/mod_rewrite.so
Find all occurrences of
and change them to
Also read : How to Change Default Timezone in Apache/PHP
3. Restart XAMPP,WAMP
Restart XAMPP/WAMP server to apply changes.
Also read : How to Install mod_security in CentOS 7