I came across a reusable visualforce component to sort columns in pageblocktable.It works great on other browsers but not in IE and also sorting on currency fields is not working.Has anyone used it? Is there any better way to do sorting of columns?
I would have to presume that the problem stems from the data appearing as an actual string to the sorting algorithm, thus producing lexicographical sorting (e.g. sorting as a string). You have plenty of choices to choose from if you want to introduce easy sorting: AngularJS has an orderBy directive, jQuery has a tableSort, module you can add into it (and others, just search for them), as well as most other JS frameworks. Of course, it would be fairly easy to roll your own sorting command in about 20-40 lines of code, as outlined on StackExchange.
Internet Explorer 7 and 8 are shortly losing their support in salesforce.com, and it is generally time to upgrade as developers as a whole work towards supporting standards instead of the browser/feature detection fragmented past spawned by the browser wars. Make sure you're testing your code in IE 9 or, even better, IE 10, which has already dwarfed previous versions, largely thanks to the automatic upgrades provided by Microsoft.
I have followed the steps in this link and I was able to fix the sorting on my
It uses the jQuery tablesorter plugin to sort the table client-side.
Below code worked for me. Hope this helps!!