Jump to content

Archived

This topic is now archived and is closed to further replies.

Adri

result listing problem

Recommended Posts

Hey all,
I heva this problem with the listing of my results. I have a lot of entries in the database and I retreieve them with:

[code]$getentries = mysql_query("SELECT * FROM guestbook ORDER BY id DESC");[/code]

Now, I want to show them with 15 at a time. For this I use:

[code]$start = $offset (=0, 15, 30, 45, depending on which page of the results you are)
$stop = $offset + 15

for ($i=$start; $i<=$stop; $i++) { echo $whatever; }[/code]

The problem is, that when $start=15 and $stop=30 he displays the same results as when $start=0 and $stop=15. He just always takes the first 15 results out of the array :s. How come?!?

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.