1

Topic: Add a call inside the validateForm javascript function

Hello there,

I want to add a tinyMCE.triggerSave(); at the beginning inside the validateForm function, otherwise.. i get a validation error from punBB because the field is empty. (not trigger saved yet).

validateForm: function(form)
{
    tinyMCE.triggerSave();
    (..) // the function
    return true;
}

Is there a way i can 'extend' the validateForm function inside my own javascript file? i'm not really a good javascript coder but this should be simple..

var validateForm_editor = validateForm.extend(function (form) {
    ????
}); 

Re: Add a call inside the validateForm javascript function

You can redifine this mehtod. JavaScript code will look like:

Forum.validateForm = function(form)
{
    tinyMCE.triggerSave();
        ...
}