DataTables警告(表id ='我的表'):从数据源请求未知参数'0'

I have a datatable to show fields from a MYSQL database however I keep getting the error:

DataTables warning (table id = 'My Table'): Requested unknown parameter '0' from the data source

Here is my code:

      <table class="table table-striped table-bordered" id="sample_1">
                              <thead>
                                 <tr>
                                    <th style="width:8px;"><input type="checkbox" class="group-checkable" data-set="#sample_1 .checkboxes" /></th>
                                    <th>Username</th>
                                    <th class="hidden-phone">Email</th>
                                    <th class="hidden-phone">Points</th>
                                    <th class="hidden-phone">Joined</th>
                                    <th class="hidden-phone"></th>
                                 </tr>
                              </thead>
                              <tbody>
 <?php


$con = mysql_connect("localhost","cl49-XXX","XXX");
if (!$con) 
  {
   die('Could not connect: ' . mysql_error());
   }

mysql_select_db("cl49-XXX", $con)or die( "Unable to select database");


$result=mysql_query("SELECT * FROM products ")or die('You need enter a catagory ' );

  echo "<tr>"; // first row beginning
for ($i = 1; $i <= mysql_num_rows($result); $i++)
{
    $row = mysql_fetch_array($result);

    $prodname = $row['prodname'];
    $prodID = $row['prodID'];
    $catagory = $row['catagory'];

                      echo "<tr class='odd gradeX'>
                                          <td><input type='checkbox' class='checkboxes' value='1'/></td>

                      <td class='hidden-phone'>$prodID</td>
                      <td class='hidden-phone'>$prodname</td>
                                            <td class='hidden-phone'>$catagory</td>
                                            <td class='hidden-phone'><a href='deleteproduct.php?q=$prodID'><button class='btn btn-danger'type='submit'><font color='white'>Delete</font>  </a>
                                            ";


        echo "</tr><tr>"; // it's time no move to next row

}
echo "</tr>"; // last row ending
    ?>
    </tbody>
    </table>     

Does anyone know what this error means?

The number of td's should match what you have given while calling out the datatable();

Quick fix(if you do not want to customize the default functionalities) would be :

$('#sample_1').dataTable();

If you have given anything inside datatable({/configs/}) just remove it completely and it should work well.