Alias whatever
July 2, 2011 9:26 PM   Subscribe

How can I set URL forwarding to get a second domain name to point to a subpage of my Drupal site?

I have 2 domains names on an inexpensive name host, hosted at a different location where Drupal is installed.

Domain 1 goes to the configured names of the Drupal site, www.howtobesimpleminded.com; I set the DNS record to the IP number of the site, the domain name gets passed through, and it works fine.

The second domain name is just www.marksaltveit.com, and I want it to go to a subpage of the first website, the "About Mark" page. But the DNS record only wants an IP number, not 201.202.203.34/aboutmark (or whatever).

I set URL forwarding to the page, but Drupal then won't serve up the page because it's looking for "www.howtobesimpleminded.com", and apparently it's being passed "www.marksaltveit.com".

I tried deleting the DNS record altogether; then I just to to the name host's parking page. There is one setting I can change: masked URL forwarding, redirect 301 forwarding, or redirect 302. Does that make a difference? Does it matter whether I enter the IP number or some name?

Thanks
posted by msalt to Computers & Internet (3 answers total)
 
A 301 redirect from www.marksaltveit.com to www.howtobesimpleminded.com/aboutmark should work, although it will cause people to see the howtobesimpleminded.com name when they arrive.

Masked URL forwarding is probably a proxy, which may be even better (i.e. people always see marksaltveit.com) or may not quite work (depending on how the links and Javascript are set up on your site).

There are several ways to go about this at your site itself, but if your DNS provider will do it, that's probably fine.
posted by Monsieur Caution at 11:25 PM on July 2, 2011 [1 favorite]


Response by poster: Thank you very much. I set up a 301 as described; no joy yet but they warn that it may take up to a day to see results. If you can, please check back in in a day for an update, or just tell me about the ways to do this on the site itself now if you prefer. Much appreciated.

(I tried the proxy forwarding earlier, no luck but to be honest I didn't wait a day. The changes I make to the DNS lookup take effect within an hour so I've been assuming URL forwarding works on the same schedule.)
posted by msalt at 1:24 AM on July 3, 2011


Google Name Based Virtual Hosts and see if that sets you right.
posted by mhoye at 3:02 PM on July 3, 2011


« Older My computer keeps clicking!   |   Let's get some shoes. Newer »
This thread is closed to new comments.