View Full Version : "Show more" button

01-15-2012, 03:17 PM

I'm newbie with MySQL... and have a little problem. Hope someone know how to solve this.

I have one table in database... and I use this:
INSERT INTO table VALUES ( "Looong text", "1" ), ( "Loooong text", "2" ) , ( "Loooong text", "3" ), ( "Loooong text", "3" )

And page is loaded very very slowly beucase it's too much text there. I thought if it's possible to show only 1-2 rows and then to add a "show more" button and when it's pressed to show 3-4 rows. Hope someone can understand, bad english here. :(

01-16-2012, 09:31 AM
Have a look at some results under http://www.google.com/search?q=php+mysql+pagination

01-18-2012, 04:00 PM
Thanks. Use this now: http://www.phpsimplicity.com/tips.php?id=1

echo '<a href="'.$_SERVER['PHP_SELF'].'?startrow='.($startrow+2).'">Next</a>';
$prev = $startrow - 2;
if ($prev >= 0)
echo '<a href="'.$_SERVER['PHP_SELF'].'?startrow='.$prev.'">Previous</a>';

But "Next" and "Previous" is show twice, what do? Thanks.

01-19-2012, 04:15 PM
nobody? :(

01-21-2012, 11:54 AM

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum