Go Back   CodingForums.com > :: Client side development > General web building

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-16-2013, 02:42 AM   PM User | #1
codingrox
New Coder

 
Join Date: Jun 2012
Posts: 32
Thanks: 12
Thanked 0 Times in 0 Posts
codingrox is an unknown quantity at this point
Force Browser to request for another domain using DNS?

If browser requests for www.foo.com then I want to send back a DNS response (answer) to the browser which would make browser to ask request DNS entry for www.bar.com. This time if I see request for www.bar.com, I would let it follow through and let the DNS system reply with 'A' record for www.bar.com.


In short I want to force browser to go to another domain using DNS. I referred CNAME record but it does not seem possible to achieve this using CNAME records. Can you please suggest something?


Can it be done using DNS or would I have to look for another technique.
codingrox is offline   Reply With Quote
Old 03-20-2013, 08:27 PM   PM User | #2
patryk
Regular Coder

 
patryk's Avatar
 
Join Date: Oct 2012
Location: /dev/couch
Posts: 395
Thanks: 2
Thanked 64 Times in 64 Posts
patryk is on a distinguished road
you can do that using DNS if your DNS server will allow you to remove all A records and leave only CNAME.
otherwise you can use redirection in .htaccess file (and that's prolly better idea)
patryk is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:05 PM.


Advertisement
Log in to turn off these ads.