simple example
<?php
$database_db = 'bookmarks';
include_once('database_class.egn');
$HOW_MANY = 10;
if (!isset($pos))
$pos = 0;
$pos_prev = $pos - $HOW_MANY;
$pos_next = $pos + $HOW_MANY;
$product_count = $database->count('site', '');
$result = $database->select_array('', 'site', "LIMIT $pos, $HOW_MANY");
foreach($result as $pos => $val)
echo $val['site_address'] ."<br>\n";
if ($pos_prev >= 0)
echo "
<a href='$PHP_SELF?pos=$pos_prev'>Back</a>
";
echo "
<a href='$PHP_SELF?pos=0'>Home</a>
";
if ( $pos_next < $product_count )
echo "
<a href='$PHP_SELF?pos=$pos_next'>Next</a>
";
?>
""Mike"" <[EMAIL PROTECTED]> wrote in message
98lff3$4ec$[EMAIL PROTECTED]">news:98lff3$4ec$[EMAIL PROTECTED]...
I have a Mysql Database on a web site.On very large record retrieval I want
to split the recorset so there is "Page 1, Page 2...."links at the
bottom.This is the only part I dont have.Any Suggestions?
Thank
Mike P
[EMAIL PROTECTED]
--
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]
--
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]