...

View Full Version : "Show more" button



cat250
01-15-2012, 04:17 PM
Hi!

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. :(

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

cat250
01-18-2012, 05: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.

cat250
01-19-2012, 05:15 PM
nobody? :(

cat250
01-21-2012, 12:54 PM
Fixed.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum