I have no idea if this is possible so thought I'd ask those for more knowledgeable here.
I'm doing some work on a client website. I've set up a virtual site locally using apache 2 so that I can have a mirror copy of the site to make changes and test before uploading to the live site. At the moment I'm switching between the local and remote sites by editing the IP address in /etc/hosts. What I'd like to know is if there is any way to set up local dns so that I can resolve "examplesite.com" to either my local virtual site, or the real live site based on the specified http port. i.e.: If I visit examplesite.com (standard port 80) I'll go to the live interent site. But if I visit examplesite.com:81 I'll be redirected to the local development virtual site running on my local computer. Probably can't be done but thought I'd ask and see what suggestions you guys can come up with.