tigrang / cakephp-datatable

JQuery DataTable plugin server-side processing component for CakePHP
47 stars 29 forks source link

Change Page issue fix #26

Closed codebymark closed 11 years ago

codebymark commented 11 years ago

I was having trouble with the pagination changing pages, so I modified the DataTableComponent _paginate() method to include this line at the bottom:

$settings['page'] = 1 + ($this->_params['iDisplayStart'] / $limit);

I haven't looking into the documentation enough but I don't think that the offset parameter works.

Note: I am using Cake lib v2.1.3.

luisillo26 commented 11 years ago

Really really true!!

tigrang commented 11 years ago

I'll look into this when I get a chance.

tigrang commented 11 years ago

Cake takes the page number and with the limit sets the 'offset' key. Pagination has always worked for me. Marking as closed.