How do I change the class of the submit buttons in the main editor modal?
How do I change the class of the submit buttons in the main editor modal?
bsuk
Posts: 92Questions: 26Answers: 2
Hopefully this is a simple one, but I've searched everywhere and can't find this..
I just want to change the button class of my bootstrap "create" button to "btn btn-success" instead of it's default "btn btn-default"
I tried in the i18n section but it doesn't seem to work..
It's easy with the actual datatable buttons as they are called in the datatable code, but I can't see how to customise the editor modal ones.
Many thanks.
This discussion has been closed.
Answers
I wish to do the same, is there a solution?
Hi,
If you are using the
create
button (etc) you can useformButtons
option of that button type to define the buttons you want to display. For example:The
formButtons
object it passed intobuttons()
which defaults what values it can take. It appears the fact that you can set aclassName
parameter is missing from that documentation at the moment - sorry! I'll correct that forthwith!Regards,
Allan
Thanks Allan, but that doesn't seem to be working.
I just get the standard "confirm" button when I apply that code.
Are there any additional steps that I could be missing?
Hi,
Did you update the
className
to bebtn btn-success
? Also, if you right click on the button and select "Inspect" does it show the class or not?If it isn't there, could you show me your full Editor code, or give me a link to the page please?
Thanks,
Allan