Hey, there! Look at our new WYSIWYG editor.
Documentation

Click-to-Edit

clickStart #

Triggered when Click-to-Edit is started. In other words when a user click on the inactive editor.

$R('#content', {
    callbacks: {
        clickStart: function()
        {
            // ...
        }
    }
});

Listen to the message in a plugin:

(function($R)
{
    $R.add('plugin', 'myplugin', {
        init: function(app)
        {
            // define app
            this.app = app;
        },

        // messages
        onclickStart: function()
        {
            // ...
        }
    });
})(Redactor);

clickStop #

Triggered when Click-to-Edit is stopped and get ready to the start call.

$R('#content', {
    callbacks: {
        clickStop: function()
        {
            // ...
        }
    }
});

Listen to the message in a plugin:

(function($R)
{
    $R.add('plugin', 'myplugin', {
        init: function(app)
        {
            // define app
            this.app = app;
        },

        // messages
        onclickStop: function()
        {
            // ...
        }
    });
})(Redactor);

clickSave #

Arguments
html String HTML code as the result of editing

Triggered whenever Click-to-Edit's Save button is pressed.

$R('#content', {
    callbacks: {
        clickSave: function(html)
        {
            // ...
        }
    }
});

Listen to the message in a plugin:

(function($R)
{
    $R.add('plugin', 'myplugin', {
        init: function(app)
        {
            // define app
            this.app = app;
        },

        // messages
        onclickSave: function(html)
        {
            // ...
        }
    });
})(Redactor);

clickCancel #

Arguments
html String the initial HTML code which sets before the editing

triggered whenever Click-to-Edit's Cancel button is pressed.

$R('#content', {
    callbacks: {
        clickCancel: function(html)
        {
            // ...
        }
    }
});

Listen to the message in a plugin:

(function($R)
{
    $R.add('plugin', 'myplugin', {
        init: function(app)
        {
            // define app
            this.app = app;
        },

        // messages
        onclickCancel: function(html)
        {
            // ...
        }
    });
})(Redactor);