The script works very fine,very thanks.
But my problem start at this step:
// dynamic page number links (make sure to change yourpage.php to the name of your page)
for ($i=1; $i<=$pagenums; $i++) {
if ($i!=$page) {
echo " <a href='yourpage.php?page=$i' class=main>$i</a>";
}
else {
echo " <b class='red'>$i</b>";
}
}
because my page is called "index.php?action=$action&key=$key"
where
$action is the condition that start the query
and $key is the key search of the query.
If in the script I put :
for ($i=1; $i<=$pagenums; $i++) {
if ($i!=$page) {
echo " <a href='index.php?action=$action&key=$key&page=$i' class=main>$i</a>";
}
else {
echo " <b class='red'>$i</b>";
}
}
my loop start again from the beginning and display again the first LIMIT results of the query.
How can I get the script to work displaying correctly the other pages?
Thanks for any help.