tabulator: $(...).tabulator is not a function

below is the codes. i have loaded tabulator.js and the other css or js ,and i am sure all the paths are right. i need help as soon as possible .thanks @.

<script src="${ctx}/IF1580/jquery-ui-1.12.1/external/jquery/jquery.js"></script>
<script src="${ctx}/IF1580/jquery-ui-1.12.1/jquery-ui.min.js"></script>
<link href="${ctx}/IF1580/tabulator-master/dist/css/tabulator.min.css" rel="stylesheet">
<script type="text/javascript" src="${ctx}/IF1580/tabulator-master/dist/js/tabulator.min.js"></script>`
`$("#example-table").tabulator({
        height:205, // set height of table
        fitColumns:true, //fit columns to width of table (optional)
        columns:[ //Define Table Columns
            {title:"Name", field:"name", width:150},
            {title:"Age", field:"age", align:"left", formatter:"progress"},
            {title:"Favourite Color", field:"col"},
            {title:"Date Of Birth", field:"dob", sorter:"date", align:"center"},
        ],
        rowClick:function(e, row){ //trigger an alert message when the row is clicked
            alert("Row " + row.getData().id + " Clicked!!!!");
        }
    });
    var tabledata = [
        {id:1, name:"Oli Bob", age:"12", col:"red", dob:""},
        {id:2, name:"Mary May", age:"1", col:"blue", dob:"14/05/1982"},
        {id:3, name:"Christine Lobowski", age:"42", col:"green", dob:"22/05/1982"},
        {id:4, name:"Brendon Philips", age:"125", col:"orange", dob:"01/08/1980"},
        {id:5, name:"Margret Marmajuke", age:"16", col:"yellow", dob:"31/01/1999"},
    ];

//load sample data into the table
    $("#example-table").tabulator("setData", tabledata);`

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 15 (4 by maintainers)

Most upvoted comments

the order looks right,

have you checked to make sure the contents of the included files is correct, also are you getting any other errors in your console before the tabulator issue?

Cheers

Oli

ok . i have resolved this problem .haha… i didn’t load the newest tabulator.js .

thanx Oli, great product