I need to pass a value from parent to iframe using javascript but both are in different domain.
i tried using the below but still i am unable to achieve this, after passing the text i need to send enter key to go to the next page
<!DOCTYPE html>
<html>
<body>
<iframe id="myFrame" src="https://sitechecker.pro/iframe-test/" style="height:380px;width:100%"></iframe>
<button onclick="myFunction()">Try it</button>
<script>
function myFunction() {
var iframe = document.getElementById("myFrame");
var elmnt = iframe.contentWindow.document.getElementsById("minitool_input")[0];
elmnt.innerHTML = "http://google.com";
}
</script>
</body>
</html>