<!DOCTYPE html>
<html>
    <head>
<script src="https://cdn.datatables.net/1.13.11/js/jquery.dataTables.js"></script>
<link href="https://cdn.datatables.net/1.13.11/css/jquery.dataTables.css" rel="stylesheet" type="text/css" />
<link href="https://cdn.datatables.net/select/1.0.0/css/select.dataTables.css" rel="stylesheet" type="text/css" />
<script src="https://cdn.datatables.net/select/1.0.0/js/dataTables.select.js"></script>
                <script src="https://code.jquery.com/jquery-1.9.1.min.js"></script>
        
        <meta charset=utf-8 />
        <title>DataTables - JS Bin</title>
    </head>
    <body>
        <div class="container">
            <table id="tblexample" class="" width="100%">
                <thead>
                    <tr>
                        <th>Name</th>
                        <th>Position</th>
                        <th>Office</th>
                        <th>Age</th>
                        <th>Start date</th>
                        <th>Salary</th>
                    </tr>
                </thead>
                <tfoot>
                    <tr>
                        <th>Name</th>
                        <th>Position</th>
                        <th>Office</th>
                        <th>Age</th>
                        <th>Start date</th>
                        <th>Salary</th>
                    </tr>
                </tfoot>
                <tbody>
                    <tr>
                        <td>Tiger Nixon</td>
                        <td>System Architect</td>
                        <td>Edinburgh</td>
                        <td>61</td>
                        <td>2011/04/25</td>
                        <td>$3,120</td>
                    </tr>
                
                    <tr>
                        <td>Ebony Grimes</td>
                        <td>Software Engineer</td>
                        <td>San Francisco</td>
                        <td>48</td>
                        <td>2010/03/11</td>
                        <td>$2,875</td>
                    </tr>
                    
                    <tr>
                        <td>Martena Mccray</td>
                        <td>Integration Specialist</td>
                        <td>Edinburgh</td>
                        <td>46</td>
                        <td>2011/03/09</td>
                        <td>$4,080</td>
                    </tr>
                </tbody>
            </table>
        </div>
    </body>
</html>
 
body {
    font: 90%/1.45em "Helvetica Neue", HelveticaNeue, Verdana, Arial, Helvetica, sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: #fff;
}
div.container {
    min-width: 980px;
    margin: 0 auto;
}
 
$(document).ready( function () {
  var table = $('#tblexample').DataTable();
  //html = '<tr><td>123</td><td>123</td><td>123</td><td>123</td><td>123</td><td>123</td></tr>';
  table.fnAddData(['222', '333']);
} );
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers