RE: Table help needed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: Chris Payne [mailto:oxygenet32@xxxxxxxxx]
> Sent: Friday, October 19, 2012 7:01 PM
> To: <php-general@xxxxxxxxxxxxx>
> Subject:  Table help needed
> 
> Hi everyone,
> 
> So i'm stuck, and I admit it.  I have to (QUICKLY) display information
> from a database, easy.  But the formatting they want is in a HTML
> table, 3 columns at a time and unlimited rows - how can I display 3
> columns across at a time?  Please help, it's a last minute thing !!!
> 
> Chris


$query = "SELECT * TABLE";
$result = mysql_query($query);
If(mysql_num_rows($result) >= 1)
{
Echo "<table>";
	While($row = mysql_fetch_assoc($result))
	{
	Echo
"<TR><TD>".$row[field1]."</TD><TD>".$row[field2]."</TD><TD>".$row[field3]."<
/TD></TR>
	}
Echo "</table>";
}








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



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux