Is there a bug in home page example?

Is there a bug in home page example?

setsusetsu Posts: 1Questions: 0Answers: 0
edited May 2011 in General
If I sort the second column I get

Trident Internet Explorer 4.0 Win 95+ 4 X
Trident Internet Explorer 5.0 Win 95+ 5 C
Trident Internet Explorer 5.5 Win 95+ 5.5 A
Trident Internet Explorer 6 Win 98+ 6 A
Tasman Internet Explorer 4.5 Mac OS 8-9 - X
Tasman Internet Explorer 5.1 Mac OS 7.6-9 1 C
Tasman Internet Explorer 5.2 Mac OS 8-X 1 C
Trident Internet Explorer 7 Win XP SP2+ 7 A

Why "Internet Explorer 4.5" entry doesn't follow the string order?

I expect the following result

Trident Internet Explorer 4.0 Win 95+ 4 X
Tasman Internet Explorer 4.5 Mac OS 8-9 - X
Trident Internet Explorer 5.0 Win 95+ 5 C
Trident Internet Explorer 5.5 Win 95+ 5.5 A
Tasman Internet Explorer 5.1 Mac OS 7.6-9 1 C
Tasman Internet Explorer 5.2 Mac OS 8-X 1 C
Trident Internet Explorer 6 Win 98+ 6 A
Trident Internet Explorer 7 Win XP SP2+ 7 A

It's correct?
Setsu

Replies

  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin
    The reason is that the sort there is string sorting, rather than natural sorting. There is a plug-in for natural sorting if you want that: http://datatables.net/plug-ins/sorting#natrual - but I wanted to keep the home page example very simple.

    Allan
This discussion has been closed.