Latest news
Home » zendframework (page 3)

zendframework

php zend Pagination

Zend pagination Zend pagination is a default option available in zend framework. Only needs to use it .The codes are apply in  controller and view class Admin_PollsocietiesController extends Core_Controller_Action { public function listsocreqAction() { $oSocReqs   = new Model_Societysignup(); $aSocReqs   = $oSocReqs->getPendingRequests(); unset($oSocReqs); //for pagination $climit  = 20; $page1 = $this->_getParam(‘page’,1); $paginator = Zend_Paginator::factory($aSocReqs); $paginator->setItemCountPerPage($climit); $paginator->setCurrentPageNumber($page1); $this->view->paginator=$paginator; $this->view->assign(‘aSocs’, $paginator); } } ...

Read More »