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
    New Coder
    Join Date
    May 2006
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    fill dropdown list with items when parent list changed

    I have two fields in my db size and colors I store my data like that:

    size colors
    8 red,blue
    10 red
    12 white

    I have two dropdown lists the first for size and the second for size I made a select query and get the sizes I want but I want when I select a specific size the second list display the colors , also I know how to populate a comma seprated field but what should I do so the seconde list change its values

    (without ajax please)

    thanks

  • #2
    Senior Coder
    Join Date
    Mar 2005
    Location
    Portsmouth UK
    Posts
    4,511
    Thanks
    3
    Thanked 504 Times in 491 Posts
    if you want this done client side

    server side will need to construct some arrays to populate the second select list

    for example populate select script see

    http://www.vicsjavascripts.org.uk/Fo...endium.htm#f14
    Vic

    God Loves You and will never love you less.

    http://www.vicsjavascripts.org/Home.htm

    If my post has been useful please donate to http://www.operationsmile.org.uk/

  • #3
    New Coder
    Join Date
    May 2006
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thanks alot but how to get the colors value string from the database
    (I have already a record set that have my colors values)


  •  

    Posting Permissions

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