I am doing simple shopping site and I only know how to view the products from the database in table such as this code below.
<table width ="793" align ="center" border ="5" >
<tr bgcolor ="red">
<th width="90">product No </th>
<th>User Name </th>
<th width="184">product name</th>
<th>product price</th>
<th>Edit product</th>
<th>Delete product</th>
</tr>
<?php
mysql_connect("localhost","root","root");
mysql_select_db("db");
$query = "SELECT * FROM products";
$run = mysql_query($query);
while($row = mysql_fetch_array($run))
{
echo "<tr>";
echo '<td align="center"><font color="white"><b>' . $row['id'] . '</b></td>';
echo '<td align="center"><font color="white"><b>' . $row['product_name'] . '</b></td>';
echo '<td align="center"><font color="white"><b>' . $row['product_price'] . '</b></td>';
echo '<td align="center"><a href="edit.php?id=' . $row['id'] . '"><font color=" #e52d00"> <b>Edit</b></a></td>';
echo '<td align="center"><a href="delete.php?id=' . $row['id'].'"><font color=" #e52d00"><b>Delete</b></a></td>';
echo "</tr>";
}
echo "</table>";
?>
</body>
</html>
and I want to know how to view data in way such as amazon or ebay. I mean inside table.
I hope you know what I mean.