Monday, July 17th, 2006

AJAX pagination made simple (with Symfony)

Category: PHP, Programming

Users of the PHP framework symfony are no strangers to easy-to-use functionality, and in this new post on the symfony blog, they share yet another – an Ajax pagination method.

Paginated lists in web pages imply specific controls to navigate across pages (link to previous and next page, link to a specific page, etc.). And lists are paginated because they are often too big to load. But when AJAX comes in, this last constraint disappears, and the specific controls can easily be replaced by a more intuitive tool: The browser’s scroll bar.

They include both an image/demo with an example of how the functionality works as well as (of course) the PHP code to make it all happen.

Posted by Chris Cornutt at 7:46 am
7 Comments

+++--
3.7 rating from 283 votes

7 Comments »

Comments feed TrackBack URI

Very nice! I was just about to jump into a ‘lazy paging’ system for a web app that has a large recordset currently broken up by the classic ‘pagination’ method. This article will come in handy I think!

Comment by Mike Ritchie — July 17, 2006

Symfony is an incredible web programming framework. Be warned that Symfony has a bit of a steep learning curve, but it is definitely worth it when get used to using Symfony. The Ajax integration in the framework makes Symfony a very powerful tool. Symfony is to PHP as Rails is to Ruby.

Comment by Sean — July 17, 2006

Symfony simple rocks !

Comment by snk00sj — July 19, 2006

i love symfony!
a while ago i was trieing some php5 frameworks and decided to use symfony. Bisides the fact that symfony has nearly all i needed it is very well documented!

Comment by tuct — August 4, 2006

Yea, but it is tough to install. I had a nighmare going when I was installing it.

Comment by Paul — August 23, 2006

This pagination creates the problem it’s trying to solve. Now you HAVE to go from page 1 to N, one by one. It looks nice, but it’s not clever.

Comment by snlr — September 8, 2006

@Paul, it’s a basic example that’s easily expanded upon.

Comment by Ian — November 16, 2006

Leave a comment

You must be logged in to post a comment.