1

I am trying to add a check box to a single column jQuery data table using

dataTable.fnAddData( ["<input type=\"checkbox\">"]);

I don't get any error messages but nothing shows up.

OtagoHarbour
  • 3,969
  • 6
  • 43
  • 81

2 Answers2

1

I needed to do

dataTable.fnAddData( ["<input type='checkbox' id='checkboxID'/>"]);
jQuery('#checkBoxID').show();
OtagoHarbour
  • 3,969
  • 6
  • 43
  • 81
0

You need to add \ before escape character.

dataTable.fnAddData( ["<input type=\\"checkbox\\">"]);

Check this SO Question.

Community
  • 1
  • 1
Praveen
  • 55,303
  • 33
  • 133
  • 164