42 users online (0 members and 42 guests)  

Thread: pull down menu


Page 1 of 2 1 2 Last
  Results 1 to 15 of 16

Related

  1. pull down menu issue    Forum: HTML Forum
    Replies: 0
  2. Replies: 0
  3. Pulldown menu blocks my popup menu    Forum: HTML Forum
    Replies: 9
  4. Replies: 3
  5. I need a pull down menu    Forum: HTML Forum
    Replies: 1
  1. #1
    allstarr
    allstarr's Avatar
    Guest

    Talking pull down menu

    You know that "pull-down" thing you told us how to make? How do you make it so when you pick one option, it links or does the action you tell it too. Namely links.

    ------------------
    Eat It!

  2. #2
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    There are 2 you need to copy and paste into your page

    This part goes inbetween the <head> and the</head> tags, although not immediately after <head>, this first line should be reserved for the <title>

    <SCRIPT LANGUAGE="JavaScript">

    <!-- Begin
    function formHandler(form){
    var URL = document.form.site.options[document.form.site.selectedIndex].value;
    window.location.href = URL;
    }
    // End -->
    </SCRIPT>


    This part gets placed inside the body where ever you want it.

    <form name="form">
    <select name="site" size=1>
    <option value="">Go to....
    <option value="http://www.yahoo.com">Yahoo
    <option value="http://www.spaceports.com">Spaceports
    <option value="http://apollo.spaceports.com/~ahfb">HTML Help
    </select>
    <input type=button value="Go!" onClick="javascript:formHandler(this)">
    </form>


    Dave

    Last edited by HTML; 05-19-2002 at 08:03 AM.
    AHFBWEB Less customers per server, more power for you!

    Business Class Shared Hosting

  3. #3
    allstarr
    allstarr's Avatar
    Guest

    Talking

    There seams to by a problam. The one part, "directory.title..."whatever that part is, it says it's not right. Am I supposed to put somethine in their place? If I am, give an example.

    ------------------
    Eat It!

  4. #4
    allstarr
    allstarr's Avatar
    Guest

    Talking

    "document.form.site.options[document.form.site.selectedIndex].value;"

    Thats what the part is that needs to be fixed.

    ------------------
    Eat It!

  5. #5
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    the only things that need to be changed are the link urls and the link titles

  6. #6
    allstarr
    allstarr's Avatar
    Guest

    Smile

    Give an exampe please

    ------------------
    Eat It!

  7. #7
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    The following is the part you put in the body, donot forget the part that goes in the head.

    Take yahoo for instance, If you wanted it to be alts vista instead, you would Change the addresss givin and the link name Yahoo.

    <form name="form">
    <select name="site" size=1>
    <option value="">Go to....
    <option value="http://www.yahoo.com">Yahoo
    <option value="http://www.spaceports.com">Spaceports
    <option value="http://apollo.spaceports.com/~ahfb">HTML Help
    </select>
    <input type=button value="Go!" onClick="javascript:formHandler(this)">
    </form>


  8. #8
    allstarr
    allstarr's Avatar
    Guest

    Talking

    Ok, heres what I have:<head>

    <SCRIPT LANGUAGE="JavaScript">

    <!-- Begin
    function formHandler(form){
    var URL = document.form.site.options[document.form.site.selectedIndex].value;
    window.location.href = URL;
    }
    // End -->
    </SCRIPT>

    <form name="form">
    <select name="www.angelfire.com/anime2/allstarr" size=1>
    <option value="www.angelfire.com/anime2/allstarr">Pictures
    <option value="www.angelfire.com/anime2/allstarr">Utilities
    <option value="www.angelfire.com/anime2/allstarr">Games
    <option value=""www.angelfire.com/anime2/allstarr">Html
    </select>
    <input type=button value="Go!" onClick="javascript:formHandler(this)">
    </form>

    </head>

    What would I change? I didn't get what u were saying.



    ------------------
    Eat It!

  9. #9
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    You have made the changes already now you just need to go back up to the original reply and find otu which part goes inside the head and which part inside the body.

  10. #10
    allstarr
    allstarr's Avatar
    Guest

    Talking

    I don't see a difference.?

  11. #11
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    part of it goes in the head part of it goes in the body, you have everything in the head and that will not work.
    If you cannot see in my first reply how to set it up you are just not reading it.

  12. #12
    allstarr
    allstarr's Avatar
    Guest

    Talking


    You mean like this?:

    <head>

    <SCRIPT LANGUAGE="JavaScript">

    <!-- Begin
    function formHandler(form){
    var URL = document.form.site.options[document.form.site.selectedIndex].value;
    window.location.href = URL;
    }
    // End -->
    </SCRIPT>
    </head>

    <body>
    <form name="form">
    <select name="www.angelfire.com/anime2/allstarr" size=1>
    <option value="www.angelfire.com/anime2/allstarr">Pictures
    <option value="www.angelfire.com/anime2/allstarr">Utilities
    <option value="www.angelfire.com/anime2/allstarr">Games
    <option value=""www.angelfire.com/anime2/allstarr">Html
    </select>
    <input type=button value="Go!" onClick="javascript:formHandler(this)">
    </form>
    </body>

  13. #13
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    Exactly like that

    Dave

    Last edited by HTML; 05-19-2002 at 08:04 AM.
    AHFBWEB Less customers per server, more power for you!

    Business Class Shared Hosting

  14. #14
    allstarr
    allstarr's Avatar
    Guest

    Talking

    why is HTML off? My web server is down for a bit, and I was hoping I could use this. It doesn't work MAYBE because I was using it not on a real web page, but in a folder on my computer. Because it doesn't work there. Well, it doesn't matter. Thanks for taking me through this process. I guess I was a little slow.

  15. #15
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Talking

    HTML is off because that is what allowed me to type the code that you copied and pasted. If HTML was on, and you were to post a question about HTML it would show the end result but not the code.

    Put it on your server, and it should work fine.

    Dave




Page 1 of 2 1 2 Last

Tags for this Thread