i need help here i want to display the data of mysql table in row and column wise. can you guys help me out. i wanna show in 3 column X 4 row wise.
This will display a 3 column table and show every row in the database table in case you expand it down the road. Change colname1, colname2, and colname3 to whatever the columns are named in your mysql table. $query = "select * from tablename"; $result = mysql_query($query); echo "<table>"; while($row = mysql_fetch_object($result)) { echo "<tr><td>" . $row->colname1 . "</td><td>" . $row->colname2 . "</td><td>" . $row->colname3 . "</td></tr>; } echo "</table>"; PHP: