Skip navigation

Lets learn how to enable mod_rewrite on apache2 on ubuntu linux to be able to implement SEO based links and to be able to run other .htaccess settings . TO enable mod_rewrite follow the steps as shown below.

Open your terminal window through Applications->Accessories->Terminal and type in the followg commands

1. ap2enmod rewrite

now open the /etc/apache2/sites-available/000-default

and change AllowOverride None to AllowOverride All .(this appears at around three places in the file.)

also in/etc/apache2/sites-enabled/000-default

3. Now restart your apache using /etc/init.d/apache2 restart

Now you can check for the correctness by placing a .htaccess file in the desired web root.If everything goes fine then the configurtaions are correct else please repeat the procedure again. Hope this would help you out.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: