Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Senior Coder
    Join Date
    Jun 2002
    Location
    ColoRockyz
    Posts
    1,649
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Reset 2nd select

    I need to reset the 2nd select named "sty" to "selected" when the first one named "let" is onchanged.
    I'm close but need this kinda quickly. Thanks fellers

    <form name="sara">

    <select name="let" onchange="">
    <option selected>Desert</option>
    <option>Ocean</option>
    <option>Sky</option>
    </select>

    <select name="sty">
    <option selected>Black</option>
    <option>Green</option>
    <option>Blue</option>
    </select>

    </form>
    Zoobie or not Zoobie...That is the problem.
    <body onUnload="flush( ! )">

  • #2
    Kor
    Kor is offline
    Red Devil Mod Kor's Avatar
    Join Date
    Apr 2003
    Location
    Bucharest, ROMANIA
    Posts
    8,478
    Thanks
    58
    Thanked 379 Times in 375 Posts
    Code:
    function resetOption(){
    document.sara.sty.selectedIndex = 0;
    }
    KOR
    Offshore programming
    -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

  • #3
    Senior Coder
    Join Date
    Jun 2002
    Location
    ColoRockyz
    Posts
    1,649
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Ahh...Thanks Kor...I was thinking defaultValue.
    Zoobie or not Zoobie...That is the problem.
    <body onUnload="flush( ! )">


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •