HTML Help

jackisthemasterofwater

Totodile Smokes Crack
  • 3
    Posts
    19
    Years
    Yep, I'm helping to build a website!

    Well, we do have a slight problem. Drop-Down Lists.

    Right, I've tried standard drop down list code:

    <script language="javascript"> function jump(form) { var myindex=form.menu.selectedIndex if (form.menu.options[myindex].value != "0") { window.open(form.menu.options[myindex].value, target="TARGET NAME GOES HERE"); }}//--></script> <form name=""> <select name="menu" style="background-color:COLORHERE; font size:#pt; font-family:FONTHERE; color:COLORHERE" size="1" onchange="jump(this.form)"> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> </select></form>

    But that doesn't work. Now, I asked a friend, and she said that it doesn't work on freewebs. So does anyone know the code I can use on freewebs for a drop-down list?
     
    Code:
    <select name="url" size="1" onChange="window.open(this.options[this.selectedIndex].value,'_top')">
    <option selected>What you want</option>
    <option value="page url">display thingey</option>
    </select>
     
    jackisthemasterofwater said:
    Yep, I'm helping to build a website!

    Well, we do have a slight problem. Drop-Down Lists.

    Right, I've tried standard drop down list code:

    <script language="javascript"> function jump(form) { var myindex=form.menu.selectedIndex if (form.menu.options[myindex].value != "0") { window.open(form.menu.options[myindex].value, target="TARGET NAME GOES HERE"); }}//--></script> <form name=""> <select name="menu" style="background-color:COLORHERE; font size:#pt; font-family:FONTHERE; color:COLORHERE" size="1" onchange="jump(this.form)"> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> </select></form>

    But that doesn't work. Now, I asked a friend, and she said that it doesn't work on freewebs. So does anyone know the code I can use on freewebs for a drop-down list?
    That's odd... because Javascript works on FreeWebs.
     
    jackisthemasterofwater said:
    Yep, I'm helping to build a website!

    Well, we do have a slight problem. Drop-Down Lists.

    Right, I've tried standard drop down list code:

    <script language="javascript"> function jump(form) { var myindex=form.menu.selectedIndex if (form.menu.options[myindex].value != "0") { window.open(form.menu.options[myindex].value, target="TARGET NAME GOES HERE"); }}//--></script> <form name=""> <select name="menu" style="background-color:COLORHERE; font size:#pt; font-family:FONTHERE; color:COLORHERE" size="1" onchange="jump(this.form)"> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> <option value="URL HERE">TEXT</option> </select></form>

    But that doesn't work. Now, I asked a friend, and she said that it doesn't work on freewebs. So does anyone know the code I can use on freewebs for a drop-down list?



    cleaned html script <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>

    <script language="javascript" type="text/javascript">
    function jump(form) { var myindex=form.menu.selectedIndex if (form.menu.options[myindex].value != "0") { window.open(form.menu.options[myindex].value, target="TARGET NAME GOES HERE"); }}//-->
    </script>
    <title></title>
    </head>
    <body>
    <form name=""><select name="menu" style=
    "background-color:COLORHERE; font size:#pt; font-family:FONTHERE; color:COLORHERE"
    size="1" onchange="jump(this.form)">
    <option value="URL HERE">TEXT</option>
    <option value="URL HERE">TEXT</option>
    <option value="URL HERE">TEXT</option>

    <option value="URL HERE">TEXT</option>
    </select></form>
    <!-- --><script type="text/javascript" src="/i.js">
    </script>
    </body>
    </html>
     
    Back
    Top