jQuery: The Write Less, Do More JavaScript Library

WARNING: This server is unstable and will be retired in the next days. If you want to keep this forum available, please request immediately a migration on the Nabble Support forum. Forums that don't receive any migration request will be deleted forever.

 « Return to Thread: Not sorting money correctly

Not sorting money correctly

by shackrock :: Rate this Message:

| View in Thread

Here is the code:

$(document).ready( function () {
            // TableSorter
                                $("#results").tablesorter({
                                                                widgets: ['zebra'],
                                                                sortList: [[0,1]],
                                                                textExtraction: function(node) {
                                                                        return $(node).text();
                                                                }

                                })
                                .tablesorterPager({container: $("#pager")})
                                .tablesorterFilter({filterContainer: $("#filter-box"),
                                                          filterClearContainer: $("#filter-clear-button"),
                                                          filterCaseSensitive: false,
                                                          filterWaitTime: 100});
        });


This, even without the text extraction, does not sort money correctly.  The values are in the format:
100.34
4.93
.04
3.66
34.00

anyone else had experience with this?  Using the latest version.

 « Return to Thread: Not sorting money correctly