[jQuery] Re: Table sorter plugin not properly sorting Distance column (ie: 17 Miles)

2009-11-18 Thread Yvan
Thanks so much! Here is my final version of the script: $(document).ready(function() { $.tablesorter.addParser({ id: 'distance', is: function(s) { return false; }, format: function(s) {

[jQuery] Re: Table sorter plugin not properly sorting Distance column (ie: 17 Miles)

2009-11-17 Thread MorningZ
First, understand *why* it doesn't work: - You add "miles" to the table cell, then Tablesorter treats it as a string value Now that this is understoodd, the solution is to use a custom parser to strip out the label, here is an example http://jsbin.com/unepe/edit On Nov 17, 11:17 am, Yvan wrote

[jQuery] Re: Table sorter plugin not properly sorting Distance column (ie: 17 Miles)

2009-11-17 Thread MorningZ
First, understand *why* it doesn't work: - You add "miles" to the table cell, then Tablesorter treats it as a string value Now that this is understand, the solution is to use a custom parser to strip out the label, here is an example http://jsbin.com/unepe/edit On Nov 17, 11:17 am, Yvan wro