Answers for "change element in iframe js"

4

iframe getelementbyid

document.getElementById('myframe1').contentWindow.document.getElementById('x')
Posted by: Guest on June-12-2020
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

Code answers related to "Javascript"

Browse Popular Code Answers by Language