m2244 Posted March 5, 2013 Share Posted March 5, 2013 Hello, I am trying to create a web based tool for use around the office. What this needs to do is present a drop down menu with, at this time, 2 choices. The choice selected determines the proper database to query. I am not sure how to do this at all. Not sure if I need to use JS (which I use a lot) or AJAX (which I am not familiar with). Can anyone get me going in a direction here? Quote Link to comment https://forums.phpfreaks.com/topic/275272-how-to-select-database-from-drop-down-selection/ Share on other sites More sharing options...
rgopal101 Posted March 5, 2013 Share Posted March 5, 2013 in this section what you want to change by change the database ,like for some time or for particular user or particular page what is the purpuse of this..? Quote Link to comment https://forums.phpfreaks.com/topic/275272-how-to-select-database-from-drop-down-selection/#findComment-1416738 Share on other sites More sharing options...
cyberRobot Posted March 5, 2013 Share Posted March 5, 2013 Are you looking to keep this on the client side (JavaScript/AJAX)? If not, you could build a simple drop down menu in HTML and process the selection with PHP. The following tutorial may help: http://www.html-form-guide.com/php-form/php-form-select.html Quote Link to comment https://forums.phpfreaks.com/topic/275272-how-to-select-database-from-drop-down-selection/#findComment-1416739 Share on other sites More sharing options...
m2244 Posted March 5, 2013 Author Share Posted March 5, 2013 in this section what you want to change by change the database ,like for some time or for particular user or particular page what is the purpuse of this..? Well, when a user here in the office (internal use only) hits this page they will need to select, from a drop down menu, one of two choices. These choices correspond to one of two databases. So they make this choice, enter some other information or not and hit a 'Search' button, this will show them the matching data from the correct database. Quote Link to comment https://forums.phpfreaks.com/topic/275272-how-to-select-database-from-drop-down-selection/#findComment-1416744 Share on other sites More sharing options...
m2244 Posted March 5, 2013 Author Share Posted March 5, 2013 Are you looking to keep this on the client side (JavaScript/AJAX)? If not, you could build a simple drop down menu in HTML and process the selection with PHP. The following tutorial may help: http://www.html-form-guide.com/php-form/php-form-select.html Thanks for the help. this helps. The thing is that I need to populate another drop down based on the user's first selection. I guess this is the real challenge for me. Quote Link to comment https://forums.phpfreaks.com/topic/275272-how-to-select-database-from-drop-down-selection/#findComment-1416746 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.