I can use this code:
var OriginalFunction = CKEDITOR.tools.callFunction;
CKEDITOR.tools.callFunction=function(n,x)
{
OriginalFunction(n, x);
alert("Called From New function");
}
To add a javascript function beside the regular function of he CKeditor toolbar buttons. but i need to be able to add to a specific editor instance. so i tried:
var OriginalFunction = CKEDITOR.instances.editor1.tools.callFunction;
CKEDITOR.instances.editor1.tools.callFunction=function(n,x)
{
OriginalFunction(n, x);
alert("Called From New function");
}
But then the function i add don't work. is there another way to do that?
Thanks.