How do I forward a domain's visitors to another (both sites being owned by myself and hosted on Dreamhost)
Asked by
makemo (
531)
October 13th, 2008
I have some sites registered with Dreamhost. I am trying to find out how to forward visits to one of those sites, to another of my sites.
I’ve gathered so far, that this might be called domain forwarding (different to redirect?).
I’ve tried googling and perusing the Dreamhost forums, but can’t for the life of me find out exactly where it says how to do this, so I thought maybe Fluther would prove faster than wait for Dreamhost support to help me out.
So, how do I forward one domain to another, within Dreamhost? (Note: these two domains are on the same account at Dreamhost.)
Observing members:
0
Composing members:
0
18 Answers
See if you have an option in your admin menu (within dreamhost) for ‘domain parking’. This will solve your whole problem. You’ll just change the nameservers in the DNS of your second url to the ones that Dreamhost gives you.
Depending on who is your DNS provider, you can point one domain to another URL by using a DNS redirect.
Who hosts your domains?
Wait, are you saying that you have two separate hosting accounts and you want one domain to forward to the other (bypassing one of your two hosting packages)?
Or are you saying that you have two domains registered with dreamhost that you want to point to one hosting package?
I have one account at Dreamhost. On that account, I have multiple sites.
I have one site that I don’t wish to put any content on, but rather have it work as an automatic redirection url (should anyone visit it) to my primary site.
ahhh ok. I get you. So you essentially want both web addresses to point to the exact same place. Is that right?
I do have access to DNS settings on my Dreamhost panel, but am not sure what to change.
Yep, that’s what I’d like to do.
Say the two sites in question are:
sitename.com & longsitename.com, I wish visitors to longsitename.com to automatically jump to sitename.com. (Reason for this, is that I haven’t yet decided wich one of the short sitename or the long one that I’ll use in the future. I’ve decided upon the short name, but want to keep the other one open, if I change my mind later.)
Right, sounds good. I use to do exactly this with dreamhost but I used godaddy as a domain registrar. Let me look up a few things and I’ll see what I can find out. Gimme a sec.
You rock, bodyhead. Don’t let me steal your time, if you’re in a hurry, though.
Or you can make a file called index.php and put this inside it.
<?php
header(‘Location: http://www.whatever.com/’);
?>
That is a quick and dirty way to do a redirect.
Aah! There we have it. Thanks, both bodyhead and johnpowell.
johnpowell: yes, I’ve been thinking whether I’ll just drop in some code on the main index page on the redirecting site, and whether (?) there’s any difference doing that, as compared to make redirection settings in the Dreamhost panel… Hmm.
I’ll do some reading on the link bodyhead sent now. Thanks to both of you!
John is correct there. I’ve used the php forwarding method on a site before. There was a reason I stopped using that though. It was something concerning site engine optimization or something. I can’t remember exactly.
*note: but that was a while ago. I don’t understand the SEO of today quite as well as the ease of yesteryear.
I am guessing the difference being, is that in one scenario, your sites are still considered different sites, but in the other scenario, you actually set one site to act as an automatic alias to the prime site, no?
At any rate, my question is answered! I went for the option of doing it the way it says in bodyhead’s link there.
Yea you’re right on. I think that google use to penalize you for php redirects but not for aliases. I’m not sure if they still do or not.
Doing what the wiki suggests is best. And bodyhead is correct. Google is better with aliases.
Thanks John. That’s good to know. Truth be told I can’t stand behind a half memory as something that’s definitely correct.
Answer this question
This question is in the General Section. Responses must be helpful and on-topic.