How does the data in the drop-down list dynamically read the content of database fields? Select & nbsp; name = "cp_kh" & nbsp; id = "selModule" & gt; & nbsp; & lt; option & nbsp; value = "{$ row [$ I]}" & gt; & lt; /option & gt how does the data in the drop-down list dynamically read the content of database fields?
Select name = "cp_kh" id = "selModule">
When you click the drop-down list, the data in the drop-down list is dynamically retrieved from the database. How can I get the data of all rows under a field from the database table to the drop-down list. The drop-down list is arranged by a row of read data. Php reads data table fields and assigns values to the read data drop-down list. (How to implement it ?) For example,
PHP database
------ Solution --------------------
Vehicle type
$ SQL = "select * from cartype ";
$ Query = mysql_query ($ SQL );
While ($ result = mysql_fetch_array ($ query )){
?>
">
}
?>