title: put data attribute on row add on DataTables 1.10
body: <p>I dynamically add new row on DataTables 1.10.2 using the <code>table.row.add()</code> method using this code:</p>
  
  <pre><code>table.row.add([
      '',
      name,
      target_l,
      details,
      panel.html()    
  ]).draw();
  </code></pre>
  
  <p>I produced this mark-up:</p>
  
  <pre><code>&lt;tr role="row" class="odd"&gt;
      &lt;th&gt;1 .&lt;/th&gt;
      &lt;td class="sorting_1"&gt;ID Fee&lt;/td&gt;
      &lt;td&gt;All students&lt;/td&gt;
      &lt;td&gt;&lt;/td&gt;
      &lt;td&gt;
          &lt;button class="btn btn-null btn-xs" onclick="_remove(59, 'ID Fee')"&gt;
              &lt;span class="fui-cross"&gt;&lt;/span&gt;
          &lt;/button&gt;
          &lt;button class="btn btn-null btn-xs" onclick="_edit(59, 'ID Fee', '', '')"&gt;
              &lt;span class="icon-pencil"&gt;&lt;/span&gt;
          &lt;/button&gt;
      &lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>
  
  <p>What I want to do is to <strong>add a data-id</strong> (and other data) <strong>attribute to the newly added tr tag</strong> (on or after row insert) and make it something like this:</p>
  
  <pre><code>&lt;tr data-id="59" role="row" class="odd"&gt;
  </code></pre>
  
  <p>I've managed to get the index of the newly added row using the code and <em>it returns the last row index</em>:</p>
  
  <pre><code>var i = table.row.add([
      '',
      name,
      target_l,
      details,
      panel.html()    
  ]).index();
  </code></pre>
  
  <p>And also tried to perform the following to add the <strong>data-id attribute</strong> using <em>that</em> index:</p>
  
  <pre><code>var id = $("#department_id").val();
  table.row(i).attr("data-id", id);
  // table.row(i).data("id", id);
  // I wanted to try this but there is also a method called data() already in
  // DataTables so it will not work like in JQuery.
  </code></pre>
  
  <p>I'm new to DataTables and already scrolled its sourcecode, red the comments. Though not good at understanding its functions that begins with <code>_fn*()</code>. If there's any other way without relying on these <code>_fn*()</code> functions, thanks!</p>