How to change _TOTAL_ separator ?

How to change _TOTAL_ separator ?

demonstenesdemonstenes Posts: 2Questions: 0Answers: 0
edited May 2011 in General
Hi, first of all - Datatables is the best plugin ever !

But I canot find a solution to one problem - the default formating of _TOTAL_ field has a comma as a separator - for example 1,394. How can I change it to display value without comma (1394 or 1 394)?

Replies

  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    fnFormatNumber is the callback you are looking for here: http://datatables.net/usage/callbacks#fnFormatNumber .

    Allan
  • demonstenesdemonstenes Posts: 2Questions: 0Answers: 0
    Thx for a reply, but I don't know how to use this callback. I have such code in my app:

    [code]
    $(document).ready(function() {

    jQuery.fn.dataTableExt.oPagination.iFullNumbersShowPages = 5;

    $('#myTable').dataTable( {
    "aoColumnDefs": [
    { "sType": "html", "aTargets": [ 0 ] }
    ],

    "sPaginationType": "full_numbers",
    "sDom": '<"top"flp>rt<"bottom"<"clear">ip',

    "oLanguage": {
    "sLengthMenu": "Poka? _MENU_ rekord
  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    There is a code example of how to use it in the documentation at the link in my previous post.

    Allan
This discussion has been closed.