djfox Posted February 14, 2010 Share Posted February 14, 2010 I`m working on a new category system for the submissions to my website. The new system is broken down into two different database tables. I know the basics of creating a form and have the original drop down selection of the form for the old category system. But for this one, what I want to do is have one select drop down menu with a list (digital, traditional, photography, etc) and depending on what the user selects there, another menu will appear containing the subcategories that belong under the first selection (ie, if they choose digital, they`ll get abstract, wallpaper, fan art, but if they choose photography, they`d get wallpaper, animals, landscape). How can this be done? I`ve looked around online, googling all day but can`t find anything that is like what I`m looking for. Quote Link to comment Share on other sites More sharing options...
jl5501 Posted February 14, 2010 Share Posted February 14, 2010 What you need is an ajax call on selection of master category, which will then populate the subcategory list. I use this on many sites and can help you if you get stuck. Also, the categories and subcategories can live in one table in the database Quote Link to comment Share on other sites More sharing options...
khr2003 Posted February 14, 2010 Share Posted February 14, 2010 Your question is related to javascript more than it does to php coding. if you google populate menus I think you will find some ready made scripts on the two or even three levels menus. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.