|
|
|
|
|
|
![]() |
#1 |
I'm going to the backseat of my car with the woman I love, and I won't be back for TEN MINUTES
|
Need help on a script "if you know" !
it's a jup menu, I need it to open the link in a new page,
It juste whont work can somone help me? <form name="form1"> <select name="menu1" onChange="MM_jumpMenu('form1.menu1.value,'_blank')"> <option>bla bla your bla bla</option> <option value="videos.html">bla bla #1</option> <option value="videos2.html">bla bla #2</option> <option value="videos3.html">bla bla #3</option> </select> <input type="button" name="Button1" value="Go" onClick="MM_jumpMenuGo('menu1','parent',1)"> </form> thanks
__________________
Submit your Free Sites |
![]() |
![]() |
![]() |
#2 |
Programming till my fingers bleed.
Join Date: Aug 2003
Location: Michigan
Posts: 876
|
You need to post the javascript code between the <head></head> tags so that we can show the code. It should be the MM_jumpMenuGo function at the top of the page.
|
![]() |
![]() |
![]() |
#3 |
I'm going to the backseat of my car with the woman I love, and I won't be back for TEN MINUTES
|
oups sorry I forgot |rasta|
<script language="JavaScript" type="text/JavaScript"> <!-- function MM_jumpMenu(targ,selObj,restore){ //v3.0 eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'"); if (restore) selObj.selectedIndex=0; } function MM_findObj(n, d) { //v4.01 var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n]; for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); if(!x && d.getElementById) x=d.getElementById(n); return x; } function MM_jumpMenuGo(selName,targ,restore){ //v3.0 var selObj = MM_findObj(selName); if (selObj) MM_jumpMenu(targ,selObj,restore); } //--> </script>
__________________
Submit your Free Sites |
![]() |
![]() |
![]() |
#4 |
Programming till my fingers bleed.
Join Date: Aug 2003
Location: Michigan
Posts: 876
|
Well if you look at the function MM_jumpMenu. It has
targ,selObj,restore So try <select name="menu1" onChange="MM_jumpMenu('_blank','form1.menu1.value,'_blank')"> See if that works. Andy |
![]() |
![]() |
![]() |
#5 |
I'm going to the backseat of my car with the woman I love, and I won't be back for TEN MINUTES
|
nop
open in the same window I try everyting, and it just wont work |pissed|
__________________
Submit your Free Sites |
![]() |
![]() |
![]() |
#6 |
If something goes wrong at the plant, blame the guy who can't speak English
Join Date: Jul 2004
Posts: 30
|
Try rip all the JS code out and add the target element like this --
Code:
<form name="form1" target="_blank"> |
![]() |
![]() |
![]() |
|
|