Home arrow MySQL arrow Building A Dynamic MySQL Paging Class With PHP
MYSQL

Building A Dynamic MySQL Paging Class With PHP


One handy class that Joe always keeps in his PHP toolbox is a custom MySQL recordset paging class, which he developed about 5 months ago. In this article Joe describes how he created the MySQL recordset paging class with PHP and also shows us how to use it with three cool examples!

Author Info:
By: Joe O'Donnell
Rating: 4 stars4 stars4 stars4 stars4 stars / 49
April 04, 2002
TABLE OF CONTENTS:
  1. · Building A Dynamic MySQL Paging Class With PHP
  2. · The class
  3. · The RecNav constructor
  4. · The ShowRecs function
  5. · Using the RecNav class
  6. · Conclusion

print this article
SEARCH DEVARTICLES

Building A Dynamic MySQL Paging Class With PHP
(Page 1 of 6 )

As PHP developers, we can develop pretty much anything that we can think of: database driven sites, complete GUI applications with PHP-GTK, XML based representations of our data, chat applications, search engines, etc.

To create applications like those mentioned above we need a diverse range of tools in our toolkit. By tools, I mean pieces of code or programs that help us develop these applications quicker and easier, such as classes, functions, IDE's and the like. One handy class that I always keep in my PHP toolbox is my custom MySQL recorset paging class, which I developed about 5 months ago. Time and time again I've found myself using this class to develop web sites for my clients, and today I'm going to show you how I created the class.

In this article we're going to work through a step-by-step format to create a highly generic, customizable MySQL recordset paging class with PHP. The class accepts custom queries and options such as the layout of the results and the number of results per page can be changed easily.

To work with the class we're about to create, you should have PHP and MySQL installed on either a Windows or Linux PC. You should also have intermediate knowledge of PHP, regular expressions and MySQL.
blog comments powered by Disqus
MYSQL ARTICLES

- MySQL and BLOBs
- Two Lessons in ASP and MySQL
- Lord Of The Strings Part 2
- Lord Of The Strings Part 1
- Importing Data into MySQL with Navicat
- Building a Sustainable Web Site
- Creating An Online Photo Album with PHP and ...
- Creating An Online Photo Album with PHP and ...
- PhpED 3.2 More Features Than You Can Poke ...
- Creating An Online Photo Album with PHP and ...
- Creating An Online Photo Album with PHP and ...
- Security and Sessions in PHP
- Setup Your Personal Reminder System Using PHP
- Create a IP-Country Database Using PERL and ...
- Developing a Dynamic Document Search in PHP ...

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 

Developer Shed Affiliates

 




© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials