Adding a button with click function in drill-down/hidden row
Adding a button with click function in drill-down/hidden row
staticum
Posts: 7Questions: 0Answers: 0
Hi All,
Would someone be able to suggest in this example code : http://www.datatables.net/blog/Drill-down_rows - how can I add a button to the hidden row and attach a function to that buttons click. Basically I have a text area in a hidden row and I want to save its content back to an ajax data source on click.
Donation on the wy! Cheers.
Would someone be able to suggest in this example code : http://www.datatables.net/blog/Drill-down_rows - how can I add a button to the hidden row and attach a function to that buttons click. Basically I have a text area in a hidden row and I want to save its content back to an ajax data source on click.
Donation on the wy! Cheers.
This discussion has been closed.
Replies
You'd use the approach I mention in the other discussion with a jQuery event listener:
[code]
$('body').on( 'submit', '#SomeDataTable form', function (e) {
...
} );
[/code]
That's a form submit - obviously you could listen for a 'click' on an individual button element as well if you wanted.
Regards,
Allan