You are here: irt.org | Articles | JavaScript | Location | Array-Tours [ previous next ]
Published on: Wednesday 1st January 1997 By: Martin Webb
<html> <body> <center> <table height="100%"><tr><td> <form name="form1" onSubmit="return parent.openDoc(document.form1.select1)"> <!-- This form uses JavaScript functions in the parent frame --> <input type="button" value=" << " onClick="parent.goFirst(); document.form1.select1.selectedIndex = parent.n"> <input type="button" value=" < " onClick="parent.goBack(); document.form1.select1.selectedIndex = parent.n"> <input type="button" value=" ^ " onClick="parent.goHome()"> <input type="button" value=" > " onClick="parent.goForward(); document.form1.select1.selectedIndex = parent.n"> <input type="button" value=" >> " onClick="parent.goLast(); document.form1.select1.selectedIndex = parent.n"> <select name="select1"> <script language="JavaScript"><!-- //This script outputs an Option for each 'Link' object //contained in the 'myLink' array in the parent frame for (var i=0; i < parent.item; i++) document.write( '<option value="' + parent.myLink[i].href + '">' + parent.myLink[i].text + '<\/option>' ); //--></script> </select> <input type="submit" value="Go"> </form> <script language="JavaScript"><!-- //This script sets the selected option document.form1.select1.selectedIndex = parent.n; //--></script> </td></tr></table> </center> </body> </html>