Hi,
I'm a PHP/MySQL newbie. I have been reading a lot of PHP pagination tutorials and I noticed that most of them teach you how to show your records one after another "down" the page in rows and then after they've reached a certain limit the code will generate a new page for the overflowing records.
To better explain I've just copied this snippet from one of the tutorials I was reading:
CODE
// Start paging variables
$screen = $_GET['screen'];
$PHP_SELF = $_SERVER['PHP_SELF'];
$rows_per_page=5; // number of records per page
$total_records=mysql_num_rows($result);
$pages = ceil($total_records / $rows_per_page); // calculate number of pages required
if (!isset($screen))
$screen=0;
$start = $screen * $rows_per_page; // determine start record
$query .= "LIMIT $start, $rows_per_page";
$result= mysql_query($query) or die
("Could not execute query : $query ." . mysql_error());
I was wondering whether it was possible have the records showing one after another "across" the page (like in columns) and then when it reaches a certain limit, it breaks and then goes to the next line - showing another batch of records until it reaches the limit for that line and then breaks and goes to next line.... etc then after the limit of rows allowed for that page is reached it will THEN generate a new page for the overflowing records.
Sorry if my explanation is a bit fuzzy.
I basically want to learn how to have my data shown like on this page of Celestial Star:
http://celestial-star.net/renders/.
That's where I got the idea from.
Any help would be greatly appreciated.
Thank You for reading!