Jump to content

Listbox Help


nickptaylor85

Recommended Posts

I am wondering if anyone can help me or at least point me in the right direction.

 

I am trying to create a Dynamic Listbox with check boxes, like http://www.nickandnisse.com/screenshot.jpg

 

I have an SQL Table called Categories with the columns "Category" and "ID"

I have another table called Subcategory with the fields "ID" "Category" and "Subcategory"

 

What I'd like to do is have the listbox generate with categories as the  unique Parent and then nested below that the subcategories related to that category.

 

Hope this makes sense.....

Link to comment
Share on other sites

What you are asking is really a JavaScript problem. You may need PHP to help populate the listbox(es), but the framework to make them work will require JavaScript. So, until you have a JavaScript solution there's nothing that PHP can do with this. Moving to the JavaScript forum.

 

FYI: You might want to look into JQuery - it might already have a pre-built solution.

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.