We are moving our forum in GitHub Discussions. For questions about Phalcon v3/v4 you can visit here and for Phalcon v5 here.


I have many rows result and I don't want to show all page number. I'm using following code,

$currentpage = (int) $this->request->get("page","int");  
$paginator = new Paginator(array(
        "data" => $result,
        "limit" => 15,
        "page" => $currentpage ? $currentpage : 1,
        "showPageList" => false,
        "pageNumber" => 10,
        "pageList" =>array(10,20,50,100)
$page = $paginator->getPaginate();
$this->view->setVar("page", $page);

Can you format your code?

edited Jul '14

You can create a partial view too, and then just pick that in your index view.