Web Hosting Talk







View Full Version : Setting up CNAME...


major
10-14-2001, 04:53 AM
First of all: I am on a virtual account, and have a question regarding CNAME:

How can I set up a CNAME so that when I go to a subdomain of my site: careers.ocprices.com - it then points to a domain on another server ?

I'm on a Linux box running Apache.

I found out that I could set this up at Gandi.net, where I bought my domain. Sorry

major
10-15-2001, 10:37 AM
OK, apparantly I did NOT know how to set it up ;). If anyone knows how to set this up in .htaccess, please let me know:

careers.ocprices.com should point to ocprices.tech-engine.com so that careers.ocprices.com is the URL you 'see'...

CagedTornado
10-17-2001, 12:38 AM
AFIK this isn't something that's possible in an .htaccess file. CNAMES refer to specifc DNS entry types. If you were running BIND 9.x, I could give you the syntax for a CNAME, but I'm not sure that's what you're looking for. The syntax for a redirect in an .htaccess file is pretty straightforward...

(All on one line)

redirect /myvirtualdirectory http://www.domain.com/redirectedvirtualdirectory

... but this won't show the original URL in the 'address' bar of the browser (a CNAME via DNS is what you want).

Dan

JDF
10-17-2001, 01:16 AM
I think the only way to do this would be to use a 0% or 0 pixel frame at the top or bottom of the page.

major
10-17-2001, 06:18 AM
Thanks for your help. Gandi.net allows me to set up a CNAME, but when I did it changed my main domain name servers... Anyone know how to make the CNAME for that subdomain and NOT affect the other parts of the site ?!

Kevin2001
10-17-2001, 07:48 AM
I've been using www.mydomain.com for about a year now and they offer free dns service for your domain. Their setup is straight forward and robust and there is no limit on the amount of hits to your domain.

Kevin