Index: lams_tool_assessment/web/pages/learning/parts/essay.jsp =================================================================== diff -u -r77b4acbb21c1e869cf55db8614ac8a84d1ea4b9a -rfc44abcc2ae14bb6a9654b8a4b03f31c4bd2bd15 --- lams_tool_assessment/web/pages/learning/parts/essay.jsp (.../essay.jsp) (revision 77b4acbb21c1e869cf55db8614ac8a84d1ea4b9a) +++ lams_tool_assessment/web/pages/learning/parts/essay.jsp (.../essay.jsp) (revision fc44abcc2ae14bb6a9654b8a4b03f31c4bd2bd15) @@ -36,11 +36,8 @@ }; if (${question.allowRichEditor}) { - // @todo Make this more elegant (.on('change') once we upgrade to Ckeditor 4 - CKEDITOR.instances["question${status.index}"].on('paste', counter${status.index}); - CKEDITOR.instances["question${status.index}"].on('afterCommandExec', counter${status.index}); - CKEDITOR.instances["question${status.index}"].on("instanceReady", function(){ - this.document.on("keyup", counter${status.index}); + CKEDITOR.instances["question${status.index}"].on("instanceReady", function(){ + this.on("change", counter${status.index}); }); //count words initially CKEDITOR.instances["question${status.index}"].on('instanceReady', counter${status.index});