I want to build a form like this
Rookie one, find similar code on the Internet, modify a pass, the effect is not what you think
Want to realize the function, the product is listed in the database of all goods, in the box to select the representative to buy the product, ask for guidance. Code as follows,
<title>Product Enquiry</title>
| Buy |
Product Name |
Single time of delivery |
Order Notes |
Include (' conn.php ');//Connect to database. mysql_query ("Use Sale_system"); $sql =mysql_query ("Select commodity from Stock"); $info =mysql_fetch_array ($sql); do{?>
Buy
|
| |
|
Noon Afternoon At night |
} while ($info =mysql_fetch_array ($sql)); ?>
|
Reply to discussion (solution)
Except for this.I don't see the big question.
The check box is named in array mode.
But the ID cannot have the same name, otherwise there will be problems with JS operation
Value should be the unique identifying information (usually the ID) of the product, or you will not know what to buy
<title>Product Enquiry</title>
| Buy |
Product Name |
Single time of delivery |
Order Notes |
| Buy |
|
NoonAfternoonAt night |
|
Sorry, it was wrong.
<title>Product Enquiry</title>
noon PM Option value= "Night" selected> night
| buy |
trade name |
Send single session |
Order notes |
!--? phpinclude (' conn.php ');//Connect to the database. mysql_query ("Use Sale_system"), $sql =mysql_query ("Select commodity from Stock"), $info =mysql_fetch_array ($sql); do{?-->
| |
|
remarks |
!--? Php}whil E ($info =mysql_fetch_array ($sql));? -->
|