Answers for "how to block iframe change url"

CSS
2

change element in iframe

// so you got an iframe (id="myiframe"). In that page you have an element id="theprice" and you want to change its value
// from the parent page do this in your javascript:
var iframevar = document.getElementById('myiframe');
var elmnt = iframevar.contentWindow.document.getElementById("theprice");
elmnt.innerHTML = theNewPrice;
Posted by: Guest on July-10-2020
0

update links inside iframe content from different domain

It isn't possible. The whole point of the Same Origin Policy is that you can't
access or manipulate content from another domain.
Posted by: Guest on May-03-2021

Browse Popular Code Answers by Language