FLY TO THE ZENITH OF SUCCESS

Arun Raj.R (Software Engineer)

Symfony 1.4 Doctrine Pagination made simple

, , ,

Doctrine Pagination is made very simple .

public function executeIndex(sfWebRequest $request)
{
$this->pager = new sfDoctrinePager('TableName', sfConfig::get('app_max_jobs_on_homepage');
$this->pager->setQuery(Doctrine::getTable('TableName')->createQuery('a'));
$this->pager->setPage($request->getParameter('page', 1));
$this->pager->init();
}

Source : http://www.techaspirant.com/symfony-1-4-doctrine-pagination

Plot Consultant :: Kerala Real Estate portal DevelopmentCreating XML-RSS Feed Using PHP MYSQL

Comments

Unregistered user Saturday, November 19, 2011 10:34:57 AM

hardik writes: yeah its works -Thanks

Unregistered user Tuesday, November 29, 2011 2:09:27 PM

Anonymous writes: This works, but only shows the first page. How do I get it to display the rest?

Write a comment

New comments have been disabled for this post.

May 2012
M T W T F S S
April 2012June 2012
1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31