mercsen
mercsen

Reputation: 692

how to prevent a event in tinymce

i have a problem working with the tinyMCE (thanks for this superb documentation!! irony)

all i'm searching for is a similar method to jQuerys event.preventDefault() but i want to stop the events fired by the editor.

i tried to use the execcommand_callback: function(editorID,elem,event) attribute at the initialization but all i get is a string (editorID), a html node (elem) and another string which contains the name of the current executed event, no event object. I could manipulate the node where the command will be executed but this wont help me preventing the event.

To disable all Buttons or the whole editor is not an option, any ideas? is this even possible?

i googled the whole weekend and everyone wants to disable the buttons :-/

Upvotes: 4

Views: 1688

Answers (1)

Niko Sams
Niko Sams

Reputation: 4404

Those callbacks are not "real" browser events.

Try return true to stop calling next callback in chain.

Upvotes: 3

Related Questions