• Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

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