protected function makePagerFromArray($data, $page = 1, $limit = 10)
    {
        $adapter = new ArrayAdapter($data);
        $pager   = new Pagerfanta($adapter);
        $pager->setMaxPerPage($limit);
        $pager->setCurrentPage($page);

        return $pager;
    }
protected function makePagerFromArray($data, $page = 1, $limit = 10)
    {
        $adapter = new ArrayAdapter($data);
        $pager   = new Pagerfanta($adapter);
        $pager->setMaxPerPage($limit);
        $pager->setCurrentPage($page);

        return $pager;
    }
protected function makePagerFromArray ( $ data , $ page = 1 , $ limit = 10 ) { $ adapter = new ArrayAdapter ( $ data ) ; $ pager = new Pagerfanta ( $ adapter ) ; $ pager -> setMaxPerPage ( $ limit ) ; $ pager -> setCurrentPage ( $ page ) ; return $ pager ; }
Creates a pager from an array

@param     $data
@param int $page
@param int $limit
@return Pagerfanta
Creates a pager from an array