jQuery TableSorter plugin is quite useful, but sometime, our actual requirement will be a bit special, following are the custom code for some special requirement.
1.Disable header using metadata
Add class attribute to those particular column header like following
<th class="{sorter: false}">column name</th>
2.Setting column parser using metadata
Add class attribute to those particular column header like following
<th class="{sorter: 'text'}">column name</th>
<th class="{sorter: 'procent'}">column name(20%)</th>
3.Custom sorting for those special column
e.g
Overall Grades |
bad |
good |
medium |
Following code can be used,
4. Custom Date Sorting
example 1,
Date |
21/01/2010 |
02/03/2010 |
12/10/2010 |
Following custom code can be used,
example 2,
Date |
Jan 6, 2012 |
May 6, 2010 |
Oct 16, 1909 |
Following custom code can be used,
For more base knowledge of jQuery TableSorter Plugin, please refer http://tablesorter.com/docs/