Search This Blog

Sunday, January 30, 2011

Enable mode rewrite in apache2 ubuntu

This command works fine in ubuntu ,login as the root and type the following command to enable mode_rewrite.

sudo gedit /etc/apache2/sites-available/default


In the following section change AllowOverride None to AllowOverride All.


 Options Indexes FollowSymLinks MultiViews
 AllowOverride None
 Order allow,deny
 allow from all
 # Uncomment this directive is you want to see apache2's
 # default start page (in /apache2-default) when you go to /
 #RedirectMatch ^/$ /apache2-default/



use rewrite rules

sudo a2enmod rewrite



Restart Apache


sudo /etc/init.d/apache2 restart

No comments: