why not simply call $row = mysql_fetch_array($result) again inside the
loop?

Sincerely

      berber

Visit http://www.weberdev.com Today!!! 
To see where PHP might take you tomorrow.


-----Original Message-----
From: valentino [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 1:43 AM
To: [EMAIL PROTECTED]
Subject: [PHP-DB] parsing 2 results per row in different <td>'s


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


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to