From: Leo Koppelkamm Date: Mon, 25 Apr 2011 13:15:26 +0000 (+0000) Subject: Followup to r86108: jQuery tries to be too smart and converts the string to a number... X-Git-Tag: 1.31.0-rc.0~30571 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=b16efcada2b17fbe29f5e8fc52a74dd241416eda;p=lhc%2Fweb%2Fwiklou.git Followup to r86108: jQuery tries to be too smart and converts the string to a number, which breaks the value parser --- diff --git a/resources/jquery/jquery.tablesorter.js b/resources/jquery/jquery.tablesorter.js index 1f60e1b3e1..50073d80d8 100644 --- a/resources/jquery/jquery.tablesorter.js +++ b/resources/jquery/jquery.tablesorter.js @@ -209,10 +209,8 @@ } function getElementText( node ) { - var n = $( node ); - var sortValue = n.data('sort-value'); - if ( typeof sortValue != 'undefined' ) { - return sortValue; + if ( node.hasAttribute && node.hasAttribute( "data-sort-value" ) ) { + return node.getAttribute( "data-sort-value" ); } else { return n.text(); }