Pagination Cache Plugin
Pagination Cache Plugin
theConartist
Posts: 14Questions: 3Answers: 0
Hi,
I was wondering if there is an available option/plugin that enables browser caching of loaded pages/rows.
I was thinking of implementing an ajax pagination but wanted to keep the viewed pages as hidden, 1. for performance, 2. i'm rendering input fields to each row and need to access them on submit.
Is there something available?
Thanks.
This discussion has been closed.
Answers
Like this?
Allan
thanks.
and how do i merge this implementation with mine. im currently using the fnServerData for my ajax request
i am currently using jquery 1.10.2 and datatables 1.10.0. i can't really upgrade them right now
That page uses DataTables 1.10, so yes.
No - it caches a set number of pages. For example page display is 10 - it will request the data for 5 pages total and hold them. It isn't a full cache in the sense of if a page has been seen once, a request for it would never hit the server again. You would need to write the code to do that if that is what you wanted.
Using server-side processing you can't. Regardless of this plug-in or any other. Server-side processing means that each time a row is displayed new nodes are created for it.
You'd need to modify the Ajax request that the plug-in makes.
Allan
thanks for the response. after a couple of hours of tinkering, i still couldn't achieve what i wanted.
I was wondering how the rows().nodes() are populated. i was aiming for this. that i would want to cache the actual rows instead of the data of the rows.
i think a modification of the rendering of rows. fnCallback contains _fnAjaxUpdateDraw, i was wondering what you are using for the non-ajax datatable to render the next rows and hide the previous rows
The internal
_fnAddRow
and_fnCreateTr
functions are the key to adding new rows. Externally you can userow.add()
to add a new row using an existing node (for example from a cache), butrow.add()
is a client-side function and therefore is useless with server-side processing.There basically is no external way to cache the nodes with server-side processing enabled. The
_fnCreateTr
function is where you would start if you want to modify the source to add that ability.Allan