Shane McBride wrote:
> If I have a MySQL DB that has 50 records in it and I want to display 5 per page. How
>do I do this. Also, 50 was just a nice round number, the number will change
>constantly.
$sql = "select * from table limit 0,5"; <-- first 5
$sql = "select * from table limit 5,5"; <-- next 5
$sql = "select * from table limit 10,5"; <-- next 5
etc.
AMK4
--
W |
| I haven't lost my mind; it's backed up on tape somewhere.
|____________________________________________________________________
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ashley M. Kirchner <mailto:[EMAIL PROTECTED]> . 303.442.6410 x130
SysAdmin / Websmith . 800.441.3873 x130
Photo Craft Laboratories, Inc. . eFax 248.671.0909
http://www.pcraft.com . 3550 Arapahoe Ave #6
.................. . . . . Boulder, CO 80303, USA
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]