I've written these lines of code in order to crate my dynamic(fetch data from a database) checkbox.
**<?php
db_connect();
$sql = mysql_query('SELECT title FROM products WHERE cname LIKE "Coffee"') or die(mysql_error());
while($row = mysql_fetch_array($sql, MYSQL_BOTH)){
echo "<input type='checkbox' name='products[]' value='".$row['title']."'>"
.$row['title'];
}
?>**
The problem is that the results come in the same line in my webpage, but I'd like them to be appeared as a list so as to create an order-list /menu of me cafeteria. How can I correct this?