Datatables 1.10 sort only by cliking sort icons in th
Datatables 1.10 sort only by cliking sort icons in th
Hi,
I am using datatables version 1.10. I have a requirement where
(1) when clicked on sort icons (up and down arrows) sorting should work server side
(2) when clicked on th , sorting should work locally
this is because user clicks on thead by mistake and servers gets unwanted burden.
Objective: I wanted to keep both
(1) local sorting [clicking thead not icons](only for data currently in table display/page)
(2) server side sorting [only by clicking icons].
THE PROBLEM:
DataTables uses css background-image for sorting. This makes it difficult to detect click on icons since css background-image can not be captured on clicks as per my knowledge.
This is the solution i have come up so far but it is not working.
any help will be much appreciated.
http://jsfiddle.net/bababalcksheep/mae29pau/16/