Event for ckeditor content changed

后端 未结 5 418
挽巷
挽巷 2021-01-01 15:48

If possible, how can we to the event of ckeditor\'s content being changed? For instance, there\'s some text already inserted into the ckeditor\'s content aka textarea when t

5条回答
  •  佛祖请我去吃肉
    2021-01-01 16:38

    Simple jQuery event binding for CKEditor4

    $.fn.onDataChange = function (func) {
        var func = func || function () { };
        CKEDITOR.instances[$(this).attr('id')].on('change', function () {
            func();
        });
    }
    

提交回复
热议问题