Apply DataTable on a dynamic table with different th outputs

Apply DataTable on a dynamic table with different th outputs

lalatilalati Posts: 1Questions: 1Answers: 0

Hello i have a list of users and for each one a link that outputs a table with user info and dynamic data such as questions for this users and their answers in Th and Td correspondingly, the table headers questions can very alot between users.
Now that was the first problem, the second one is :
"TypeError: $(...).DataTable is not a function"
Although i included the js load file before the data tables js one

Answers

  • kthorngrenkthorngren Posts: 21,307Questions: 26Answers: 4,947

    TypeError: $(...).DataTable is not a function

    This can happen for a variety of reasons. Please post a link to your page or a test case showing the issue.

    Kevin

  • allanallan Posts: 63,471Questions: 1Answers: 10,467 Site admin

    The most common reason is that you are loading jQuery multiple times. But really we'd need a test case as Kevin notes and as noted in the forum rules.

    Allan

This discussion has been closed.