Please help sort "158 450.00 ek." currency

Please help sort "158 450.00 ek." currency

RozmanRozman Posts: 7Questions: 1Answers: 0
edited September 2013 in General
Hello, I read FAQ and Plugins and can't understand how to sort rows with this string "158 450.00 ek."
I need that DataTables removes " ek.", removes space between numbers and can understand ".00" too.

Thank you very much for working example.

JSFiddle - http://jsfiddle.net/HEDvf/643/

Replies

  • RozmanRozman Posts: 7Questions: 1Answers: 0
    edited September 2013
    (comment removed)
  • ThalliusThallius Posts: 31Questions: 4Answers: 0
    There is a good example how you can write your own sort function. This will be the only way i guess.

    Claus
  • RozmanRozman Posts: 7Questions: 1Answers: 0
    Where there?
  • ThalliusThallius Posts: 31Questions: 4Answers: 0
    Just read the manual about sorting here. You just have to add your own type of sorting. Easy going
  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395
    Rozman, if you control the data source, don't include ek. in your currency field. That will simplify any further data handling, although as Thallius says, you will need to read up on custom sorting for Datatables.
  • RozmanRozman Posts: 7Questions: 1Answers: 0
    Ok, stackoverflow helps me.
    If somebody will need working example - see on http://jsfiddle.net/HEDvf/663/

    P.S. and doesn't need to remove ek., working with it.

    Thank you all.
This discussion has been closed.