Buttons not displaying / missing / not working (live.datatables test code provided)

Buttons not displaying / missing / not working (live.datatables test code provided)

cclarkcclark Posts: 7Questions: 3Answers: 0

I'd appreciate some help getting buttons to work. I have simple working code here. Ideally, I'd like to know how to make it work within Datatables, but also with the constructor (the commented part).
I'm using the libraries as shown in the code, so jquery 3 with the latest datatables.
I don't see any errors in the browser console.

I haven't submitted a debugger, because it doesn't work on live.datatables. Once I have seen it working there, and what my mistake is, I'll probably be able to apply it locally. If not, I'll be happy to share more info at that stage.

Thanks very much in advance for your help
CC

This question has an accepted answers - jump to answer

Answers

  • kthorngrenkthorngren Posts: 21,336Questions: 26Answers: 4,953
    Answer ✓

    Are you trying to create custom buttons? If so see the Custom buttons docs. Otherwise Datatables will be looking for built-in buttons called 'Button1', 'Button2', 'Button3', 'Button4'.

    Plus you should only use B or the Direct insertion method but not both for the same set of buttons.

    Updated test case to use the direct insertion method and to create custom buttons.
    https://live.datatables.net/guqaloye/5/edit

    Kevin

  • cclarkcclark Posts: 7Questions: 3Answers: 0

    I was following the Constructor section of the Buttons documentation. The page you've provided is much clearer. Thank you for the clarification, Kevin.

Sign In or Register to comment.