Flukey Posted April 18, 2006 Share Posted April 18, 2006 Hey guys,Basically, can someone please point in the right directon to do the following:I have a table i extrapolate data from. I want to display 10 records per page, if there is more than 10 records, then page 2 is created, if there is more than 20 records than page 3 is created etc.....How does one do this? Such as a forum, where post 11 goes on to page 2, post 21 goes onto page 3 etc....Thanks,Regards,Flukey Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/ Share on other sites More sharing options...
acey99 Posted April 18, 2006 Share Posted April 18, 2006 this an sql statement ? Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28400 Share on other sites More sharing options...
Flukey Posted April 18, 2006 Author Share Posted April 18, 2006 [!--quoteo(post=366243:date=Apr 19 2006, 12:24 AM:name=Acey)--][div class=\'quotetop\']QUOTE(Acey @ Apr 19 2006, 12:24 AM) [snapback]366243[/snapback][/div][div class=\'quotemain\'][!--quotec--]this an sql statement ?[/quote]to do?i'm using sql to get the data:[code] SELECT * FROM posts [/code] Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28403 Share on other sites More sharing options...
Caesar Posted April 18, 2006 Share Posted April 18, 2006 [a href=\"http://www.phpfreaks.com/tutorials/43/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/43/0.php[/a] Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28404 Share on other sites More sharing options...
Flukey Posted April 18, 2006 Author Share Posted April 18, 2006 [!--quoteo(post=366247:date=Apr 19 2006, 12:47 AM:name=Caesar)--][div class=\'quotetop\']QUOTE(Caesar @ Apr 19 2006, 12:47 AM) [snapback]366247[/snapback][/div][div class=\'quotemain\'][!--quotec--][a href=\"http://www.phpfreaks.com/tutorials/43/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/43/0.php[/a][/quote]Ah, fantastic!Thanks a lot, i appreciate your help. My apologies for not finding that link, to be honest, i didn't know it was called 'Pagination'. So no wonder i found no results! :PThanks againFlukey :) Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28412 Share on other sites More sharing options...
Caesar Posted April 19, 2006 Share Posted April 19, 2006 You're welcome...No problem. Happy coding! Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28414 Share on other sites More sharing options...
Flukey Posted April 19, 2006 Author Share Posted April 19, 2006 [!--quoteo(post=366257:date=Apr 19 2006, 01:14 AM:name=Caesar)--][div class=\'quotetop\']QUOTE(Caesar @ Apr 19 2006, 01:14 AM) [snapback]366257[/snapback][/div][div class=\'quotemain\'][!--quotec--]You're welcome...No problem. Happy coding![/quote]cheers :D I won't implement the pagination until later on. I'll report back if i get it working :) Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28482 Share on other sites More sharing options...
reaper7861 Posted April 19, 2006 Share Posted April 19, 2006 [!--quoteo(post=366247:date=Apr 18 2006, 06:47 PM:name=Caesar)--][div class=\'quotetop\']QUOTE(Caesar @ Apr 18 2006, 06:47 PM) [snapback]366247[/snapback][/div][div class=\'quotemain\'][!--quotec--][a href=\"http://www.phpfreaks.com/tutorials/43/0.php\" target=\"_blank\"]http://www.phpfreaks.com/tutorials/43/0.php[/a][/quote]Agrees its perfect. Link to comment https://forums.phpfreaks.com/topic/7790-10-records-per-page-if-there-is-10-records-make-a-new-page-etc/#findComment-28523 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.