Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Redirect from domain name to a dotted quad hosted box

Tags:

php

dns

hosting

I have a php server that is running my domain name. For testing purposes I am running an asp.net on a dotted quad IP. I am hoping to link them together via either PHP or some kind of DNS/.htaccess voodoo.

So if I go to www.mydomain.com/test it redirects (but keeps the url of (www.mydomain.com/test) in the browser's address bar and the pages are served by the dotted quad IP asp.net box.

like image 557
Chad Boyer Avatar asked Sep 05 '08 15:09

Chad Boyer


1 Answers

Instead of pointing www.yourdomain.com/test at your test server, why not use test.yourdomain.com?

Assuming you have access to the DNS records for yourdomain.com, you should just need to create an A record mapping test.yourdomain.com to your test server's IP address.

like image 116
Will Harris Avatar answered Oct 19 '22 05:10

Will Harris