想要實現(xiàn)在達到最大字數(shù)的時候,就禁止再繼續(xù)輸入了或者超出字數(shù)限制后,不能完整保存內(nèi)容。
查閱很多資料,武林網(wǎng)總結(jié)解決方法如下:
第一步:在/include/ueditor/ueditor.all.js中找到這兩行注釋掉
countDom.innerHTML = errMsg;
editor.fireEvent(“wordcountoverflow”)
第二步:在注釋點的兩行下面寫上這三行就搞定了
var content = editor.getContentTxt();
editor.setContent(content.substring(0,max));
editor.focus(true);




















