Toolbar Button Functionality - Adding Javascript

  •  10-01-2008, 9:59 AM

    Toolbar Button Functionality - Adding Javascript

    Hey,
     
    I am trying to add some javascript to the save button of the editor.  Is it possible to do this and if so is there documentation somewhere on how?  I asume I can't change the code directly but there must be some class that handles the button and it's features.
     
    Thanks in Advance
     
     
     EDITED
     

    I found the documentation:

    This event is invoked when the command button is clicked.
    Example:

     

    function CuteEditor_OnCommand(editor,command,ui,value)
     {
        //handle the command by yourself
       if(command=="InsertEmotion")
       {
          var answer = confirm("Click OK to stop this command.")
          if (answer){
             return true;
          }
          else{
             return false;
          }
       }
    }

    But it doesn't seem to work, do I need to tell the editor to start looking at this javascript function?

View Complete Thread