RE: Sepating MySQL result set into html tables

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

 



On Fri, 2008-09-26 at 13:50 -0400, admin@xxxxxxxxxxxxxxxxxxx wrote:
> Might I suggest you count the fields and divide it by the cols you want to display? 
> Example
> $forest = mysql_query("SELECT * FROM your_table");
> $gump = mysql_num_fields($forest);
> 
> Because I know my table contains 15 rows I can do this.
> $tulip = floor($gump /5);

You have a bug if you have 16 rows.

Cheers,
Rob.
-- 
http://www.interjinn.com
Application and Templating Framework for PHP


-- 
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