: Use same domain for two websites, depending on customer IP Here's the scenario I want to know if possible and how: Scenario Domain (www.foo.com) at one hosting provider. Two websites, one at
Here's the scenario I want to know if possible and how:
Scenario
Domain (www.foo.com) at one hosting provider.
Two websites, one at bar.com and another one at biz.com, each at a different hosting provider.
Actions
When a user enters foo.com, depending on the IP location, it will
load bar.com or biz.com. It is important that the user sees foo.com (masking, not redirecting).
So a user from UK would navigate foo.com website (which is really bar.com) and a user from France would navigate foo.com website (which is really biz.com).
So far I have managed to find a "fix" which would consist of loading a small website with an iframe at the foo.com hosting, and loading the corresponding website in it. I'm wondering if there's a more elegant solution than this.
More posts by @Nimeshi995
1 Comments
Sorted by latest first Latest Oldest Best
Iframe will not work because you want to keep links e.g. from bar.com to bar.com/contact look like to foo.com/contact.
So, as @deceze said, you need to set up reverse proxy but also you need to configure something which will make search and replace inside the servers response. Perhaps there are many such tools, but just to name one: privoxy.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.