houssam_ballout Posted December 30, 2012 Share Posted December 30, 2012 Hello, I had the following issue and I need your assitance in it: I had a drop down box which list the customers (from customers table), when the client select another client, I need to change the contetnt of another text box (which is the value get from BalanceTable) Any assistance? Thanks Link to comment https://forums.phpfreaks.com/topic/272522-drop-down-box-onchange-populate-another-textbox-from-mysql-table/ Share on other sites More sharing options...
cpd Posted December 30, 2012 Share Posted December 30, 2012 You would need to use AJAX to retrieve the value and then call something along the lines of document.getElementById(ID of element to change).value = dataReturnedByXHR Link to comment https://forums.phpfreaks.com/topic/272522-drop-down-box-onchange-populate-another-textbox-from-mysql-table/#findComment-1402252 Share on other sites More sharing options...
BrettHartel Posted December 31, 2012 Share Posted December 31, 2012 Or, every time the client chooses another client, you could have it set a cookie value that would set the missing value on reload. depends on what you want really. Link to comment https://forums.phpfreaks.com/topic/272522-drop-down-box-onchange-populate-another-textbox-from-mysql-table/#findComment-1402284 Share on other sites More sharing options...
houssam_ballout Posted December 31, 2012 Author Share Posted December 31, 2012 Thanks, are there examples to see? Link to comment https://forums.phpfreaks.com/topic/272522-drop-down-box-onchange-populate-another-textbox-from-mysql-table/#findComment-1402297 Share on other sites More sharing options...
Muddy_Funster Posted December 31, 2012 Share Posted December 31, 2012 Try working through these : http://www.tizag.com/ajaxTutorial/ Link to comment https://forums.phpfreaks.com/topic/272522-drop-down-box-onchange-populate-another-textbox-from-mysql-table/#findComment-1402302 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.