I want to create a form that autofills the value of two divs dynamically depending on user input. In this case the user inputs a zipcode into a jqxinput once the zipcode is entered and the focus of the input is lost I want to query the database(mysql) to retrieve the state and city values which are returned via json or ajax to symultaneously autofill the values of the state and city divs. I am having trouble with the specific technique to accomplish this because it is my first time attempting to implement ajax/json and therefore I would appreciate a specific example. I can determine the solution by looking at the example rather than an explanation, but if both are submitted I would appreciate it greatly.