i have one iframe on my page which has a different domain to that of my site. i know i can’t access anything inside the iframe from the parent window, but can i make that iframe take over my entire page – ie redirect the parent to the url of the iframe?
so far i have tried things like
window.location.href = iframe.contentWindow.location.href;
but the browser won’t allow that – i guess it isn’t smart enough to realise that the = assignment is for the purposes of redirecting and not storage for later inspection.
is there another way of doing this on all modern browsers?
How about: