Reputation: 11448
I am trying to make a dynamic form which retrives data. How can I use javascript to load a value from a mysql database?
I understand that it must use php in some way, and I know how to query the database and assign the value to a php variable, but I have no idea what to do after that...any advice?
the goal is to have someone enter their orderid say, then the datbase auto pulls down and enters their last invoice in the field below it after they click GO...
Upvotes: 0
Views: 399
Reputation: 2698
Try the W3 schools AJAX (which is what you are trying to use) tutorial: http://www.w3schools.com/ajax/default.asp
It will walk you through using AJAX and give you example code so you can do specifically what you want to do and other simple AJAX functions you may want to do.
Upvotes: 1