parsing 2 results per row in different <td>'s

From: Date: Wed, 27 Mar 2002 23:42:59 +0000
Subject: parsing 2 results per row in different <td>'s
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-17960@lists.php.net to get a copy of this message
i'm having trouble telling php to format the output of a mysql query correctly. i not only want to loop the output in simple table rows (meaning that php parses one result per row), instead i want php to parse two results per row in different <td>'s. no clue what i'm talking about? take my following simplyfied code: .... $result = @mysql_query("SELECT * FROM news"); ... while ( $row = mysql_fetch_array($result) ): ... <tr> <td><?=$row["newsBODY"]?></td> </tr> .... endwhile; --- the output would look like: <html> <tr> <td>blabla</td> </tr> <tr> <td>lalala</td> </tr> <tr> <td>doowaadee</td> </tr> <tr> <td>yipeeiyo</td> </tr> --and so on-- what i want is the following output <tr> <td>blablabla</td> <td>lalala</td> </tr> <tr> <td>doowaadee</td> <td>yipeeiyo</td> </tr> --and so on-- got the point? i really do appreciate your help! thx, val

« previous php.db (#17960) next »