Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sorting fails if row contains numbers and letters #25

Open
LiamDawe opened this issue Jun 23, 2019 · 3 comments
Open

sorting fails if row contains numbers and letters #25

LiamDawe opened this issue Jun 23, 2019 · 3 comments

Comments

@LiamDawe
Copy link

Not sure how to best describe it.

Sorting will fail, if any row has a mix of both numbers and letters. It seems to always put those with numbers before anything else. This seems really wrong.

You can see it here: https://imgur.com/a/xNZNGBt

The issue should be obvious.

@stuartlangridge
Copy link
Owner

It looks like sorttable is misdiagnosing that column as being numeric when it's actually alphanumeric. You can override its automatic column detection as https://www.kryogenix.org/code/browser/sorttable/#overrides explains; it might help to change the <th> for the column to <th class="sorttable_alpha"> and see if that helps?

@LiamDawe
Copy link
Author

I did think of that and tested it, sorry should have noted, my bad. Sadly, it did not help. No difference in behaviour.

@stuartlangridge
Copy link
Owner

Can you show me the actual HTML for the table? (A subset which exhibits the problem is fine.) A link to a URL with it in would be useful but if it's still internal or secret then pasting the HTML of the page (or emailing it to me) will let me look at it and work out what's going on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants