Jump to content

List Box onChange


aeroswat

Recommended Posts

Let me paint a picture for you of my situation... I have a listbox that is dynamically filled from a mysql database with PHP. I have 3 check boxes on the right side of this list box that each correspond to a different part of the records from that database. I want to be able to adjust the checkboxes based on what item is selected in the listbox. So let's say one of my options in the list box is Apple and the three check boxes on the right are labeled Red, Green, Yellow. This apple is sort of greenish red so in the database both are marked. So when you click the apple option in the list box it checks the Red and Green check boxes on the right. I know the ajax I need to use for this my only problem is what event do I need to use to show that Apple was selected? Is it onChange? onClick? something else? And can i get an example of how I would use it as well please.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.