Forum Moderators: open
I have redirected sites using frames before (which is probably what they don't want), so what redirect is the 301 one?
Enlightenment on this would be greatly appreciated!
There are two ways this could be handled. If you just want to redirect one domain to another I'm sure who you registered the first domain may have some service...but that will probally cost extra money though I've never tried this myself.
Second is via your web server software. You probally have Apache though there are a few others out there with various methods. In that case I know a basic redirect code for a single page...
.htaccess
Redirect permanent /index.html http://www.example.com
If your server is running Apache then you'll want to ask this question over at the Apache forum...
[webmasterworld.com...]
Hope the direction helps...
John
The domain being redirected will need to be hosted somewhere. If you'll be hosting it on an Apache server then as JAB Creations said the 301 redirect is rather simple:
1. Create a file called .htaccess
Note: you may have to call it something.htaccess and then change the name once you upload it to the server if Windows doesnt allow you to create a file starting with '.'
2. In the file type the following:
Redirect 301 / [newdomain.com...]
You generally dont want to put /index.html
Thanks for the clarification...didn't know you could direct a whole domain so easily! :)
John
Yeah it's odd, the only time you need to actually name the .htaccess differently is when you create it; thereafter you can download and upload it without any problems.
As far as redirecting the entire domain goes it is a bit trickier. I am not a 100% certain, but I think if you want to redirect from every existing old page to its equivalent new page on the new domain, then you may need to use mod rewrite, which I am still struggling to wrap my brain around. Hopefully someone else will be able to clarify this.