http://framework.zend.com/manual/en/zend.paginator.html
-Matt
On Mon, Sep 29, 2008 at 1:53 PM, 411161 <[EMAIL PROTECTED]> wrote:
>
> I have it working, but I am not sure how to create links for next, last,
> first, previous, numbers, etc.. I am also not sure how to handle links in
> my
> controller.
> This is what I have so far."
>
> controller:
> public function paginateAction() {
>
> $sql = 'SELECT * FROM runz_miles WHERE empl_no = 31713';
> $this->view->result = $this->db->fetchAll($sql);
> $paginator = Zend_Paginator::factory($this->view->result);
> $paginator->setCurrentPageNumber(15);
> $this->view->paginator = $paginator;
> }
>
> in my view I have:
> <table>
> <?
> foreach($this->paginator as $key => $row){
>
> echo "<tr><td>" .$row['EMPL_NO']
> . "</td>\n";
> echo "<td>" .$row['PRISM_ORG_CODE']
> . "</td></tr>\n";
> }
> ?>
> </table>
>
> How do I create the links and I how do I handle the action so that it will
> not try and call the sql again?
> --
> View this message in context:
> http://www.nabble.com/Looking-for-a-complete-Complete-Zend_Paginator-example-tp19731530p19731530.html
> Sent from the Zend Framework mailing list archive at Nabble.com.
>
>