weatherman2525
06-09-2003, 02:33 PM
Hi,
I am in need of 2 separate pulldowm menus on the same page, so that when you select an item from one of the menus it changes in the other frame, but I can't seem to get both to work. If one works the other doesn't. I do not know much of anything about JavaScript I normally just use the codes on this site. The frame it needs to change in is called "index1".
Please Help!
Adam
Here is the coding I got so far...
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title></title>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function leapto(form) {
var myindex=form1.select1.selectedIndex
parent.index1.location.href=(form.select1.options[myindex].value);
}
// End -->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function leapto(form) {
var myindex=form2.select2.selectedIndex
parent.index1.location.href=(form.select2.options[myindex].value);
}
// End -->
</SCRIPT>
</head>
<body>
<center>
<FORM NAME="form1">
<SELECT NAME="select1" SIZE=1 onChange="leapto(this.form)">
<OPTION SELECTED VALUE="0"> ------ Peace Buddy ------>
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage01.htm"> Page 1
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage02.htm"> Page 2
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage03.htm"> Page 3
</SELECT>
</FORM></center><p>
<center>
<FORM NAME="form2">
<SELECT NAME="select2" SIZE=1 onChange="leapto(this.form)">
<OPTION SELECTED VALUE="0"> ------ Peace Bears ------>
<OPTION value="http://www.peacebearworld.com/galleries/peace01page01.htm"> Page 1
<OPTION value="http://www.peacebearworld.com/galleries/peace01page02.htm"> Page 2
<OPTION value="http://www.peacebearworld.com/galleries/peace01page03.htm"> Page 3
</SELECT>
</FORM></center><p>
</html>
I am in need of 2 separate pulldowm menus on the same page, so that when you select an item from one of the menus it changes in the other frame, but I can't seem to get both to work. If one works the other doesn't. I do not know much of anything about JavaScript I normally just use the codes on this site. The frame it needs to change in is called "index1".
Please Help!
Adam
Here is the coding I got so far...
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title></title>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function leapto(form) {
var myindex=form1.select1.selectedIndex
parent.index1.location.href=(form.select1.options[myindex].value);
}
// End -->
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function leapto(form) {
var myindex=form2.select2.selectedIndex
parent.index1.location.href=(form.select2.options[myindex].value);
}
// End -->
</SCRIPT>
</head>
<body>
<center>
<FORM NAME="form1">
<SELECT NAME="select1" SIZE=1 onChange="leapto(this.form)">
<OPTION SELECTED VALUE="0"> ------ Peace Buddy ------>
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage01.htm"> Page 1
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage02.htm"> Page 2
<OPTION value="http://www.peacebearworld.com/galleries/peacebuddypage03.htm"> Page 3
</SELECT>
</FORM></center><p>
<center>
<FORM NAME="form2">
<SELECT NAME="select2" SIZE=1 onChange="leapto(this.form)">
<OPTION SELECTED VALUE="0"> ------ Peace Bears ------>
<OPTION value="http://www.peacebearworld.com/galleries/peace01page01.htm"> Page 1
<OPTION value="http://www.peacebearworld.com/galleries/peace01page02.htm"> Page 2
<OPTION value="http://www.peacebearworld.com/galleries/peace01page03.htm"> Page 3
</SELECT>
</FORM></center><p>
</html>