kev wood Posted April 2, 2009 Share Posted April 2, 2009 what i want to do i am not sure if it can be done. what i want to do is have drop down menu that the user selects an option from then depending what the option was they selected the drop down menu next to it displays all the results related to that option. this section is part of the CMS side of the site. the site has different categories the user can register there interest in but also these categories have sub sections. when a user registers there details they leave there email address. this section will be used to get all there emails address into a CSV format so the user can then email them information on the chosen category and subject. so what i want this section to do is give the user the option to select the categories from the first drop down menu then all the sub categories will populate the second drop down menu depending on the first selection. i know this can be easily done using submit buttons and only having one drop down menu per page but i would like it done with now submit button if possible. once the user has selected the category and subject then they will submit the information to get the results on a new page with just the email addresses on. all the information is stored on the server in mysql db's. Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/ Share on other sites More sharing options...
Showcase Posted April 2, 2009 Share Posted April 2, 2009 Can't be done using php alone. You're going to need javascript to change the values in a drop-down menu without reloading the page. Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/#findComment-799361 Share on other sites More sharing options...
kev wood Posted April 2, 2009 Author Share Posted April 2, 2009 thought as much. ithanks for the reply anyway. Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/#findComment-799362 Share on other sites More sharing options...
Yesideez Posted April 2, 2009 Share Posted April 2, 2009 Either that or have an onchange() event to submit the form automatically but the Javascript method will be much more professional looking. Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/#findComment-799370 Share on other sites More sharing options...
ScotDiddle Posted April 2, 2009 Share Posted April 2, 2009 Kev, If your not opposed to using javascript, XAJAX my prove useful... Here is a tutorial showing how to us XAJAX to build a dynamic dropdown select function. http://www.cricava.com/blogs/index.php?blog=6&title=get_a_taste_of_ajax_with_php&more=1&c=1&tb=1&pb=1 Scot L. Diddle, Richmond VA Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/#findComment-799377 Share on other sites More sharing options...
kev wood Posted April 2, 2009 Author Share Posted April 2, 2009 thanks for all the replies here i will mark it solved as i have got more than enough to get going with here. thanks once again for the replies. Quote Link to comment https://forums.phpfreaks.com/topic/152221-solved-drop-down-menu-help/#findComment-799508 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.