brissy_matty Posted April 7, 2007 Share Posted April 7, 2007 Hi am looking for some help with some dynamic lists & queries. I am trying to get 3 dynamic drop down which are taken from a mysql database - that part not so hard to do. what i want to happen is for a query to execute via PHP/mysql to collect the data based on the selections of these 3 listboxes & display directly underneath. Basically the first selectbox will contain hard coded values indicating a location/town then next listbox will display a list of events based on the selection of the first the third will display the date & time based on the selection of the first & second. a query would display full details of the event underneath based on the above. I can do this using PHP only however am really interested in the AJAX method as it updates the data either as changes are made or after all changes are made without the need to submitt a form each time. (Silently reloads data). If anyone knows of an good examples of something like this or has something could you please let me know. I have looked through alot of examples and nothing really does this. I found ones that displayed files using javascript. I found ones that could work with one select box. but i am yet to find a dynamic query / result type form. Cheers Matt Quote Link to comment Share on other sites More sharing options...
brissy_matty Posted April 7, 2007 Author Share Posted April 7, 2007 Nevermind worked it out. Cheers Matt Quote Link to comment Share on other sites More sharing options...
avargas Posted May 2, 2007 Share Posted May 2, 2007 Hi, This is very much like what I am working on now. I am trying to create a web-based interface to query a mysql database to sort transactions based on multiple options. Thus far, I can select an option from the first list to populate the second drop-down list; however, when I select the option from the second list, the entire page is reset and I have to reselect the first menu option. Any help would be greatly apprciated. Quote Link to comment Share on other sites More sharing options...
brissy_matty Posted June 1, 2007 Author Share Posted June 1, 2007 are you looking to have 3 drop downs or are you trying with just two? and its resetting on the third ? Quote Link to comment Share on other sites More sharing options...
avargas Posted June 6, 2007 Share Posted June 6, 2007 It is loading the second select box however when I make a selection from the second to populate the third the page does a refresh. I'm sure it is doing a refresh on the first selection too though, so I guess my question is how do use AJAX to make it not refresh the entire page? I've done several of the tutorials but I can't seem to wrap my head around it. Thanks for your help ??? 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.