Integration

In this chapter you will see how to integrate DataTable with jQuery.

jQuery integration

DataTable can be easy integrated with jQuery.

We want to show you 2 most 'interesting' situations of such integration:

  1. Initializing of a standard DataTable;
  2. Creating DataTable from an HTML table.

Initializing jQuery DataTable

A standard DataTable using jQuery can be initialized as follows:

Integration with jQuery

<div id="box" class="cont"></div>
...
 
$(".cont").webix_datatable({
    columns:[{...}],
    select:"cell",
    data:some_data
});

Related Sample: JQuery DataTable

Creating DataTable from an HTML table

To turn an HTML table into DataTable you should call method datatable() for it:

Creating DataTable from an HTML table

<table>
        <tr>
            <td width="40">id</td>
            ...
        </tr>
        ...
</table>
 
<script>
$("table").webix_datatable();
</script>

Related Sample: jQuery.Turning HTML Tables into DataTables

Back to top
If you have not checked yet, be sure to visit site of our main product Webix open source html5 framework and page of datatable product.