Coder Profile - Show off your skills, get a coder profile.
 
 
 
The Author
VBAssassin
Scott Thompson
Send A Message
Screenshot
View Full Size
_1222427191941.png ( 0.00Mb )
Rating
8.33
out of 10
( 3 Ratings )
Please login to rate source codes.

Click here to register a free account with us.
General Details
PHP (Hypertext Preprocess...
Posted 1.45 Year Ago
955 Views
Received 3 Ratings
More Codes By This Author
Pick A Random Array Eleme...
Bitwise Settings (Class)...
Compare Ratings, and Retu...
Settings Class
Dynamic Parameters (Using...
Articles By This Author
[PHP] - Lets kill the com...
How to use Memcache on Wi...
PHP Sessions = Member Dat...
Speed Up Delivery of your...
AJAX - When to use it?

Pagination Class


Description
Takes care of the hard work when creating pagination and can carry across variables between pages in the pages URL. Multiple instances of pagination can be used on a single page.
Technical
Does not pass across POST vars so they will be lost but it's not usually required to pass post vars around with pagination (bad coding practice). Improvements could be to add a template system to it and allow for mod-rewrite URL's. Max and Min page are automatically set.
Source Code
Comments
Please login to post comments.
 
VBAssassin     Posted 359 Days Ago
 
 
Why would you want to initiate it before you know the values? I decided not to do it
that way because in 99% of the cases there would be no need to. If you are not forced
to supply those values upon construction then it results in less error checking in
other methods and prevents the user from forgetting to set properties.

Kind regards,
Scott
 
CyberGeek     Posted 359 Days Ago
 
 
My two cents...

Nice! Simple and elegant. However, in my opinion there is two much overhead in the
Ctor. What if, I want to instantiate the class before knowing what my values are. Why
not create a mutator method for the instance, total per page and total items. So that
these can be set at a later time during execution.

Just a thought.
 
Binaries     Posted 1.5 Year Ago
 
 
Thanks a lot Scott, I'm stealing this one and putting it into my latest junk.
Keep the goodies coming.
 
Izzmo     Posted 1.19 Year Ago
 
 
Nice, just what I was looking for. Ported it straight into one of my classes!
Page 1 of 1
More "PHP (Hypertext Preprocessor)" Source Codes By This Author
Recently Posted "PHP (Hypertext Preprocessor)" Source Codes
Recently Rated "PHP (Hypertext Preprocessor)" Source Codes
 
 
Latest News About Coder Profile
Coder Profile Poll
Why do you get bored with programming?

Not enough time to do something productive
I run out of ideas
Too hard to show people my creations
Everything i do has too many errors, and it's too hard
I don't get bored!!!


please login to cast your vote
and see the results of this poll
Latest Coder Profile Changes
Coder Profile was last updated
1.28 Year Ago
Official Blog :: Make A Donation :: Credits :: Contact Me
Terms & Conditions :: Privacy Policy :: Documents :: Wallpapers
Version 1.46.00
Copyright © 2007 - 2010, Scott Thompson, All Rights Reserved