About Rank Sorting (1, 2, 3, 4-10, 11-20...etc)

About Rank Sorting (1, 2, 3, 4-10, 11-20...etc)

ice916ice916 Posts: 2Questions: 2Answers: 0

hi ! I need to make a Rankboard, but want foggy some Rank, like this:
Ranking | name
1 | Aname
2 | Bname
3 | ...ect
4-10 |...ect
4-10 |...ect
4-10 |...ect
4-10 |...ect
4-10 |...ect
4-10 |...ect
4-10 |...ect

So I reference datatables's sorting_manual examples
https://datatables.net/examples/plug-ins/sorting_manual

and try javascript code on this online IDE
live.datatables.net/buqiqupi/1/edit

but...output isn't what i want...

what can i do?

Thank you for any help in getting started prior!
Best Regards

william

This question has an accepted answers - jump to answer

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    Answer ✓

    Hi @ice916 ,

    There was a couple of things wrong - see working example here.

    1. column counting starts from 0
    2. the order function needs "-pre" on the end of the name,

    Cheers,

    Colin

This discussion has been closed.