vondip
vondip

Reputation: 14039

imitate iframe coming from another domain

I am trying to develop a small web application which will consist of one web applicaiton using an iframe from another domain. I am trying to test this on my local machine, and for this I need to imitate as if the iframe is coming from another domain (while it's actually on the same domin as the other web application - my computer). Can this be done? If so, how?

Thank you

Upvotes: 2

Views: 360

Answers (1)

LatinSuD
LatinSuD

Reputation: 1939

Test it through a local http server (just in case your were accesing to the local files).

Define 2 different vhosts in your http server.

Edit your etc/hosts file to add:

127.0.0.1 domain1.com 
127.0.0.1 domain2.com

So now you have 2 different sites, but running on the same computer.

Upvotes: 6

Related Questions