Re: table row
| From: | John Fishworld | Date: | Thu, 31 Jan 2002 22:55:45 +0000 |
| Subject: | Re: table row | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-83023@lists.php.net to get a copy of this message | ||
duh !
yep exactly like !
thanks ! :-))
> something like ?
>
> $cntr = 0;
> echo "<tr>";
> while ($r = mysql_fetch_array($result0))
> {
> $cntr++;
> $cityid = $r["t_city_id_city"];
> $cityname = $r["t_city_name"];
> echo "
> <td class=\"text\"><a
> href=\"city_person.php?city_id=$cityid\">$cityname</a></td>
> ";
> if ($cntr % 2 == 0) echo "</tr><tr>";
> } // from while result 0
> echo"</tr></table>";
>
>
> -----Original Message-----
> From: John Fishworld [mailto:john@webital.de]
> Sent: Friday, February 01, 2002 9:45 AM
> To: php-general@lists.php.net
> Subject: [PHP] table row
>
>
> apologies for a stupid question ! but it's late !
>
> everthings fine, mysql query, results etc
>
> but I want to produce a table with two columns instead of just one long
> column
>
> ie answer1 answer2
>
> can someone please give me a hint how to do it ?
>
> while ($r = mysql_fetch_array($result0))
> {
> $cityid = $r["t_city_id_city"];
> $cityname = $r["t_city_name"];
> echo "
> <td class=\"text\"><a
> href=\"city_person.php?city_id=$cityid\">$cityname</a></td>
> ";
> } // from while result 0
> echo"</table>";
>
> thanks in advance
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>