I've just spent a very enjoyable 2 hours working out how to do the following.
What I needed to do was redirect all the traffic from my old website to my new website.
I am running ubuntu 7.04, apache 2.
Here is what you need to do:-
1. vi /etc/apache2/sites-enabled/000-default
2. Change the word "none" to "all in the following line:
NameVirtualHost *
<VirtualHost *>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
3. Add the following code at the bottom of the file:
RewriteEngine ON
RewriteRule /.*
http://www.siteyouwanttoredirectto.com/ [R=301,L]
Recent comments
1 day 1 hour ago
1 day 6 hours ago
1 day 8 hours ago
1 day 8 hours ago
1 day 10 hours ago
1 day 15 hours ago
1 day 15 hours ago
1 day 18 hours ago
2 days 7 hours ago
2 days 8 hours ago