How can I update a table caption dynamically?
How can I update a table caption dynamically?
![Keith_H](https://secure.gravatar.com/avatar/0328d260bcf84a857eb7d527c9c4b831/?default=https%3A%2F%2Fvanillicon.com%2F0328d260bcf84a857eb7d527c9c4b831_200.png&rating=g&size=120)
var dTable = $('#table').DataTable();
I've tried both of the below. Obviously missing something simple.
dTable.caption().text('Details For ' + pParam);
dTable.caption('Details For ' + pParam);
Thanks in advance.
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
There is no
caption()
method. That will be coming in v2. At the moment you would need to use a little jQuery -$('#myTable caption').html(...)
.Allan
OK, Thank you.