I have a listbox that populates 2 fields.
How can I get the output from this form to be sent to an iFrame.
I’m trying to see how to set these input fields into variables.
Here’s a bit of what I have.
<script type="text/jscript">
function passValue() {
var ddl = document.getElementById("ddlName");
var index = ddl.selectedIndex;
document.getElementById("txtValue").value = ddl.value;
document.getElementById("txtName").value = ddl.options[index].text;
}
</script>
<P>
Course Name <input type=“text” id=“txtName” readonly=“readonly”/><BR>
Course ID :<input type=“text” id=“txtValue” readonly=“readonly”/><br>
<P>
I load values from a database into a ListBox. Then make a selection.
<select size= 5 id=“ddlName” onchange=“passValue()”>
The selected values are correctly placed into the input fields.
I’m trying to get the 2 values “txtName” and “txtValue” sent to the iframe also.
<iframe src=“http://xxx.net/iPage.html” width=“600” height=“400”> </iframe>
The iFrame has 2 input fields of the same names.
Thanks