Pagination : Current page variable

Pagination : Current page variable

mikemakusmikemakus Posts: 9Questions: 0Answers: 0
edited October 2009 in General
Hi,

I have a paginated datatable, is there a way to store the current page number in a variable ?

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    Hi mikemakus,

    The current page itself isn't stored in a variable, but you can work it out quite readily from the information in the settings object (fnSettings):

    [code]
    iCurrentPage = Math.ceil(oSettings._iDisplayStart / oSettings._iDisplayLength) + 1;
    [/code]
    This is how I calculate it in the pagination functions built into DataTables.

    Regards,
    Allan
  • rakeshrakesh Posts: 1Questions: 0Answers: 0
    Hi,
    Please help me to get the current page, in the php variable.

    Please....
This discussion has been closed.