Just getting first column

Just getting first column

bartbart Posts: 2Questions: 2Answers: 0

Hey folks,

I like to use the awesome datatables plugin but just getting the first column filled. Do you have any idea about it?

This is the JSON I get from the server:

{ "aaData" : [ [ "35",
        "Pedro Kilback",
        "963-420-2023x2249",
        "reanna50@treutel.com"
      ],
      [ "42",
        "Houston Walker DDS",
        "(163)607-7456x953",
        "theaney@quigley.com"
      ],
      [ "112",
        "Jazmin Schroeder",
        "940-072-2972",
        "molly26@fahey.biz"
      ],
      [ "128",
        "Liana Hahn",
        "(729)621-6454x271",
        "ukohler@gerhold.com"
      ],
      [ "186",
        "Kory Jast",
        "939-513-7687x979",
        "koelpin.norval@hotmail.com"
      ],
      [ "293",
        "Jovanny Brown",
        "582.118.4983",
        "jillian80@gmail.com"
      ],
      [ "344",
        "Sydnee Schultz V",
        "802-537-3501x97068",
        "sauer.bryce@walter.info"
      ],
      [ "473",
        "Dr. Jerad White PhD",
        "(508)690-0655x3136",
        "mills.emerald@harvey.com"
      ],
      [ "623",
        "Stella Cronin IV",
        "+09(8)6494436319",
        "grimes.camron@hotmail.com"
      ],
      [ "629",
        "Ms. Princess Hyatt DDS",
        "368.536.0747",
        "kamryn.olson@gmail.com"
      ]
    ],
  "iTotalDisplayRecords" : 100,
  "iTotalRecords" : 100,
  "sEcho" : 5
}
````

My JS looks like this:

jQuery(document).ready(function(){
oTable = jQuery('#IpKas2we').dataTable({

        "sPaginationType":   "simple_numbers",
        "bProcessing":   false,
        "sAjaxSource":   "<path to my JSON file>",
        "bServerSide":   true,
        "aoColumns": [{
            0:  {"mData":"client_id"},
            1:  {"mData":"name"},
            2:  {"mData":"phone"},
            3:  {"mData":"email"}                                     
        }]
    });
});

```

Thanks guys!

This discussion has been closed.