PDA

View Full Version : Other Way of redirecting


Ben
25th July 2006, 20:35
Due to the fact I forgot having a Co-Domain in a WEB, did not want to create one but anyway wanted to redirect the web, i remembered the apache command redirect.

So if you desire to redirect the web to any URL, you cann add the apache directive


redirect permanent / http://ww.mydomain.com


Docs: http://httpd.apache.org/docs/2.0/mod/mod_alias.html#redirect

hth Ben

falko
26th July 2006, 10:24
To anybody interested in the "art" of redirecting, take a look at this nice article: http://www.stevenhargrove.com/redirect-web-pages/ :)

wr19026
12th December 2006, 01:54
So if I want to use htaccess to do the redirect all I have to do is add Redirect 301 /old/old.html http://www.you.com/new.html in an .htaccess file. Nice!

Would this mean that I need to create the .htaccess file in /var/www/web1 with the following statement?
Redirect 301 /var/www/web1/web/old.html http://www.mydomain.dom/new.html

falko
13th December 2006, 13:15
Would this mean that I need to create the .htaccess file in /var/www/web1 with the following statement?
It's /var/www/web1/web or any subdirectory of it.