Input iFrame Source from Form Input I want my iFrame window to show the URL I enter from the Form Text box, To that I want the iframe src="" to be changed to the form field input. How can I do that? Here is a sample code that I intent to use.
<html>
<head>
<title>Blah.</title>
<link href="style.css"rel="stylesheet" type="text/css" />
</head>
<body>
<form>
Enter URL: <input type="text" />
<input type="submit" value="GO" />
</form>
<iframe src="" frameborder="0" marginwidth="0" scrolling="yes"></iframe>
</body>
</html>


Try this.
<html>
<head>
    <title>Blah.</title>
    <link href="style.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript">
function SetSrc()
{
document.getElementById("myIfreme").src = document.getElementById("txtSRC").value;
}
    </script>
</head>
<body>
    <form>
    Enter URL:
    <input type="text" id="txtSRC" />
    <input type="button" value="GO" onclick="SetSrc()" />
    </form>
    <iframe id="myIfreme" src="" frameborder="0" marginwidth="0" scrolling="yes"></iframe>
</body>
</html>