Click to See Complete Forum and Search --> : Customer own domain to link to customer record


leanghenglim
12-13-2010, 04:58 PM
Hi All,

I have been searching all over the net to try to find out what I seek but to no avail. I’m wondering if someone with expertise in domain management could help me out. It’s a combination of domain/host/php problem.

I have a database of customer records. Each customer has a profile page. Eg www.example.com/profile.php?cust_id=123456789

The customer would like to have their own domain linked to their profile page. Is this possible?

I have tried searching for solutions but all I found are the following:

1. Dynamic virtual hosting. The customer profile is stored in a database, so virtual hosting will not suit this situation.
2. CNAME records. I suppose I could host a DNS server, get the customer to point their domain registrar to the DNS server. The DNS server can then point www.customername.com to the alias www.example.com/profile.php?cust_id=123456789. Will this even work? Will the CNAME redirect parse the php get method variable similar to a HTTP request?
3. Mod_rewrite. Could this be possible? Get the customer to point their domain registrar to my host’s DNS server, then rewrite the URL based on the HTTP request? IE rewrite all pages where cust_id=123456789 to www.customername.com

The problem with number 2, even if it is possible, is that I can only get the one page to display. If I give the customer more pages to access such as a blog page, then I will start to see problems in terms of links.

3, if possible and can be done dynamically, would be an ideal solution…

But alas my knowledge is quite limited in the domain space so I’m not sure of any limitations. I’m not even sure if this problem can be solved.

Please help, or point me in the right direction. Thanks in advance.

leanghenglim
12-14-2010, 07:15 PM
I think I found the answer to my problem. A simple frame redirect.

This means that the customer will need to have a domain AND a hosting service. Their index page would be a frame that directs to their profile page. Of course this means that the URL would never ever change.

The disadvantage of this of course is that they're paying extra for the hosting space just for the one page. This is also an advantage in that they can use the extra hosting space for other information. They could have www.customername.com/profile/ that links to www.example.com/profile.php?cust_id=123456789. But they could also have other pages such as www.customername.com/mybusiness.htm

Although it is more a disadvantage than an advantage... why go through all that trouble and pay for extra hosting just to link to the one page...