This commit is contained in:
Aevann1 2022-03-05 23:59:35 +02:00
parent e55abf10a5
commit 4a0576cd3f

View file

@ -11,12 +11,12 @@ function sort_table(n) {
x = rows[i].getElementsByTagName("TD")[n];
y = rows[i + 1].getElementsByTagName("TD")[n];
if (dir == "asc") {
if (parseInt(x.innerHTML) > parseInt(y.innerHTML)) {
if (x.innerHTML.toLowerCase() > y.innerHTML.toLowerCase()) {
shouldSwitch = true;
break;
}
} else if (dir == "desc") {
if (parseInt(x.innerHTML) < parseInt(y.innerHTML)) {
if (x.innerHTML.toLowerCase() < y.innerHTML.toLowerCase()) {
shouldSwitch = true;
break;
}