homepage Welcome to WebmasterWorld Guest from 54.205.106.111
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Hardware and OS Related Technologies / Website Technology Issues
Forum Library, Charter, Moderators: phranque

Website Technology Issues Forum

    
Setup a Domain on A Different Host
domain setup when you have different host and different domain provider
deathlock




msg:4309766
 10:12 am on May 9, 2011 (gmt 0)

So for example I have a website www.example.com hosted on host A. And I set up a subdomain for it, let's say it's subdomain.example.com

Then I want www.anodomain.com to point to subdomain.example.com. So if someone wants to open subdomain.example.com, they should access it through www.anodomain.com

Is it possible? How to achieve it?

 

lammert




msg:4309775
 10:35 am on May 9, 2011 (gmt 0)

Hi deathlock, first of all welcome to WebmasterWorld!

Do you still want to display www.anodomain.com in the address bar of your browser, or is it OK to show subdomain.example.com there. If you don't mind which domain is shown in the address bar, a 301 redirect from one domain to the other is enough. Otherwise you have to put the second site in a frame, or use proxying between the two servers where the main server is requesting the other server for the pages, and then forwards those pages to the user.

mbabuskov




msg:4309776
 10:38 am on May 9, 2011 (gmt 0)

Either by defining CNAME record in DNS or http redirect. It depends what hostname you wish to see in the browser's address bar.

deathlock




msg:4309785
 10:55 am on May 9, 2011 (gmt 0)

I want to display www.anodomain.com in the address bar... so it will display (for example) www.anodomain.com/about.php, www.anodomain.com/forum/index.php, etc...

How to define the CNAME record in DNS? Which record should I change?

lammert




msg:4309786
 10:59 am on May 9, 2011 (gmt 0)

A CNAME in the DNS doesn't help if the webserver isn't recognizing that name. You should first make sure that the webserver is sending data if requests are coming in for www.anodomain.com, not only for subdomain.example.com. What kind of webserver software are you using?

deathlock




msg:4309819
 12:09 pm on May 9, 2011 (gmt 0)

Hmm... I'm sorry, I don't quite understand the issue...

My site (the subdomain.example.com) is hosted on a shared hosting. Meanwhile the www.anodomain.com is just a domain, without a hosting.

On the cPanel of the subdomain.example.com, it is said is hosted on Linux server, Apache version 2.2.17, MySQL version 5.0.92-community-log

deathlock




msg:4309881
 3:35 pm on May 9, 2011 (gmt 0)

Sorry, I want to edit the post but it seems I can't?

My site is hosted on a shared hosting, so I can't tell precisely what webserver software I'm using... but I believe it is Apache version 2.2.17.

So... is is it achieveable?

lammert




msg:4309885
 3:45 pm on May 9, 2011 (gmt 0)

If you are hosted on Linux, it is almost 100% sure that you have Apache. The problem with shared hosting is that you cannot just let the server listen to www.anodomain.com. That must be configured in a central file called httpd.conf, and that file is only accessible by your hosting company. Roughly there are two options:

1) ask your hosting company to add www.anodomain.com to the httpd.conf and let it point to the directory of your subdomain. This is technically the easiest solution but they may ask money for it.

2) Setup a framing or proxy server setup at your DNS provider or at another hosting company which translates www.anodomain.com requests to subdomain.example.com requests.

Technically the first one is the simplest one and I would do that. Your hosting company may ask a fee to do it, but I think that is worth it, looking at all the technical issues you'll have with the other option.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Hardware and OS Related Technologies / Website Technology Issues
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved