Master - detail AJAX select boxes - AJAX server side script
In this tutorial I will present you how to create a master - detail select box in your forms. Select one item from the master field and the details will be filled accordingly to your selection.
|Name:||Master - detail AJAX select boxes|
|Category:||AJAX basic tutorials|
|Product:||See complete product|
Bookmark Master - detail AJAX select boxes
Step 3 - AJAX server side script
Master - detail AJAX select boxes
The server side script is responsible for reading the information from the $_GET array and regarding this send back the properly formatted response string. In this example we use simple hard coded values but of course here you can make a database call as well.
The code is very simple:
And now we are ready!
On the next page you can find the complete client side code.
Previous Step of Master - detail AJAX select boxesNext Step of Master - detail AJAX select boxes
Tags: ajax select box, ajax master detail, master detail select box
|Master - detail AJAX select boxes - Table of contents|
|Step 1 - The master - detail concept|
|Step 2 - AJAX to get details|
|Step 3 - AJAX server side script|
|Step 4 - AJAX master - detail select client side code|