Click to See Complete Forum and Search --> : selected menu to open an iframe


rnadeau
04-19-2006, 06:09 PM
Good day, i got a problem with my script where my items in my selected menu have to open a different html page in my iframe
thanks

<SCRIPT type=text/JavaScript>
<!--
function changeframe(DocName) {
document.getElementById('produit').src=DocName+".html";

}

//-->
</SCRIPT>


<SELECT onchange=changeframe(this.options[this.selectedIndex].value) name=company>
<OPTION value=blanc selected>COMPANY</OPTION>
<OPTION value=yeah>YEAH</OPTION>
<OPTION value=hey>HEY</OPTION>
</SELECT>
<br>
<IFRAME id=produit name=produit src="blanc.html" frameBorder=0 width=500 height=200></IFRAME>

aj_nsc
04-19-2006, 06:15 PM
I'd just use parent.produit.location equals whatever instead of the get element by id thing.