Hello to everyone, im having some trouble in setting a position on a table in php. I learn how to display a table in php on school and with some research through the internet, but not how to customize it. Is it possible to display a mysql table from a database on a html table? Is there another way to do this? Heres my code :
<?php
include"connect_database.php";
$result = mysql_query("SELECT * from despesas_casa");
echo "<table border='1'><tr><th>Payment</th><th>Date of payment</th><th>Payment</th><th>Date of payment</th><th>Payment</th><th>Date of payment</th><th>Payment</th><th>Date of payment</th></tr>";
while ($row = mysql_fetch_array($result)){
echo "<tr>";
for($i=1;$i<9;$i++){
echo "<td>".$row[$i]."</td>";
}
echo '<td><a href="apagar.php?id_dados='.$row['id_despesa_casa'].'">DELETE</A>';
echo '<td><a href="editar.php?id_dados='.$row['id_despesa_casa'].'">EDIT</A>';
echo "</tr>";
}
echo "</table>";
?>