Results 1 to 2 of 2

Thread: Need help with multiple selectbox

  1. #1
    Join Date
    May 2007
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Need help with multiple selectbox

    Hi Guys,
    Does anybody can help me with multiple selecbox.
    I have this problem I have 2 select boxes with 3 values
    example:
    HTML Code:
    <select name="slb1">
    <option value="1">1</option>
    <option value="2">2</option>
    <option value="3">3</option>
    </select>
    <select name="slb2">
    <option value="1">1</option>
    <option value="2">2</option>
    <option value="3">3</option>
    </select>
    I want to make it when user chooses value 1 in first or second selectbox then value 1 in first or second select box must be disabled you can not choose to same values in both selectboxes
    That is the same for value 2 and three.
    Thanx in advance

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    28,951
    Thanks
    43
    Thanked 3,195 Times in 3,157 Posts
    Blog Entries
    12

    Default

    This type of exclusivity is what radio buttons are designed for. No two radio buttons of the same name may be checked at any given time. It would be difficult if not impossible to arrange this cross browser for select options. In FF and Opera, you can simply disable an option, but not in IE. Even in FF and Opera, care would need to be taken to re-enable a disabled option when a different one was selected in the other select. Radio buttons do all of this sort of thing automatically.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Bookmarks

Posting Permissions

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