First adapt the form to use data from the database:
- in the productinfo table:
- on the Structure tab add a new field after productID but before productName, call it productType and make it varchar length 30
- on the Browse tab put some data into the new field:
- for items which come in the main filling drop down put filling
- for items which are in the style of bread drop down put style
- for the types of bread put bread
- in products.php:
- leave the filling select element and the first (empty) option element alone but replace all of the other option elements with some new code:
- a PHP block to contain the new code
- a query which gets productID and productName WHERE productType is filling
- a while loop which outputs the option elements with the value attribute set to productID and the text content to productName
- do the same sort of thing for the other two drop downs by changing the WHERE condition
- leave the filling select element and the first (empty) option element alone but replace all of the other option elements with some new code:
The page should look exactly the same when you are done.