Paging or sorting?
Paging or sorting?
I apologize in advance for my English.
My question:
[code]
$ ("# example"). dataTable ({
"bProcessing": false,
"bServerSide": true,
"sAjaxSource": "Handler.ashx"
});
[/code]
On the server, I need to know if there is paging. How do I determine? I would like something like this:
[code] "fnServerParams": function (aoData) {
if (_something_){
aoData.push ({"name": "paging", "value": "true"});
}
}
[/code]
Thanks!
My question:
[code]
$ ("# example"). dataTable ({
"bProcessing": false,
"bServerSide": true,
"sAjaxSource": "Handler.ashx"
});
[/code]
On the server, I need to know if there is paging. How do I determine? I would like something like this:
[code] "fnServerParams": function (aoData) {
if (_something_){
aoData.push ({"name": "paging", "value": "true"});
}
}
[/code]
Thanks!
This discussion has been closed.
Replies
Allan
Sorting and pages always goes to the server, regardless of the action = /
I fell in love with your product, but I really need to recognize the paging :)
My form data:
sEcho:4
iColumns:33
sColumns:
iDisplayStart:10000
iDisplayLength:5000
mDataProp_0:0
-
mDataProp_32:32
iSortCol_0:1
sSortDir_0:asc
iSortingCols:1
bSortable_0:true
-
bSortable_32:true
[code]
"fnServerParams": function (aoData) {
var isPaging = false;
var beforePageStart = localStorage.getItem('pageStart');
var afterPageStart = oTable.fnSettings()._iDisplayStart.toString();
if (localStorage.getItem('pageStart'))
isPaging = beforePageStart != afterPageStart;
aoData.push({ "name": "isPaging", "value": isPaging });
localStorage.setItem('pageStart', oTable.fnSettings()._iDisplayStart);
[/code]
Allan
p.s. im russian, google translate helps me, but not always :)
Allan
Allan