Forum Moderators: open

Message Too Old, No Replies

drop down menu to link to iframe

lining a menu in one iframe to make pages appear in another iframe

         

buzzby365

12:52 pm on Jun 8, 2004 (gmt 0)



i have in index page comprising of 2 iframes, i have a menu in one iframe with links that i want to make appear in another iframe. i have the code to make information appear in an iframe but that seems to be dependant on the fact that the menu is in the same page as the iframe. here is that code that doesnt work:

the head part

<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function leapto(form) {
var myindex=form.dest.selectedIndex
parent.infoframe.location.href=(form.dest.options[myindex].value);
// You can output to ANY frame using: parent.[framename].location.href
}
// End -->
</SCRIPT>

the body part


<FORM NAME="myform">
<SELECT NAME="dest" onChange="leapto(this.form)" class="textstyle">
<OPTION SELECTED VALUE="">Choose A Link
<option value="bathroominfo.htm" >Bathroom</option>
<option value="kitcheninfo.htm">Kitchen</option>
<option value="extensioninfo.htm">Extension</option>
<option value="loftinfo.htm">Loft</option>
<option value="councilinfo.htm" >Council</option>
</SELECT>
</FORM>

can someone point out to me what is missing here? how do i link a menu in iframe1 to display information in iframe2?

korkus2000

4:48 pm on Jun 8, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Have you tried top instead of parent?