javascript - Restore table state on page reload -


i using jquery datatables plugin in project (server-side page). problem have when go details of table element (and leave table page) , return back, page number , order not preserved.

on server side can save page in session , return table send page ajax call.

how return state in table after entering item details?

solution

you can use statesave option restore table state on page reload.

for example:

$('#example').datatable({    statesave: true,   // ... other options ... }); 

demo

see this jsfiddle code , demonstration.


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

Delphi 7 and decode UTF-8 base64 -

html - Is there any way to exclude a single element from the style? (Bootstrap) -