Paginate provide a set of controls to navigate through paged data. Pagination inside Controller class RecipesController extends AppController { public $components = array('Paginator'); public $paginate = array( 'limit' => 25, 'contain' => array('Article') ); } Pagination define inside function public function list_recipes() { $this->Paginator->settings = $this->paginate; // similar to findAll(), but fetches paged results $data = $this->Paginator->paginate('Recipe'); $this->set('data', $data); } You can filter the records by passing conditions as second parameter to the paginate() function: $data = $this->Paginator->paginate( 'Recipe', array('Recipe.title LIKE' => 'a%') ); Pagination with behaviour $this->paginate=array('conditions'=...
Coding Cheatsheets - Learn web development code and tutorials for Software developers which will helps you in project. Get help on JavaScript, PHP, XML, and more.