display mysql data in two coulums ...

Codes here !

Moderators: macek, egami, gesf

Post Reply
New php-forum User
New php-forum User
Posts: 9
Joined: Fri Mar 14, 2003 7:23 pm

display mysql data in two coulums ...

Post by zeep25 » Thu Mar 20, 2003 4:14 pm

is there a way to display data from a coulum in a mysql table in to like two colums in the page .. like :

A | D
B | E
C | F

is there a way ?

Oleg Butuzov
Last Samuray
Last Samuray
Posts: 831
Joined: Sun Jun 02, 2002 3:09 am

Post by Oleg Butuzov » Sat Mar 22, 2003 11:31 pm

exemple code

Code: Select all

$query=mysql_query("SELECT * FROM `sometable`");

echo "<table border=0>";

while ($data=mysql_fetch_array($query))
     echo "<tr><td>$data[1]</td><td>$data[2]</td></tr>";

echo "</table>";

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest