JSFiddle - React, Tailwind, and code Playground

HTML

<div>
		<iframe id="src1"> </iframe>

</div>

<div>
		<iframe id="src2"> </iframe>
</div>

JavaScript

function test(){
    document.getElementById('src1').src='http://cnn.com/';
}
function test1(){
    document.getElementById('src2').src='http://w3schools.com/';
}




test();
test1();