如何计算与ckeditor一起使用的textarea中的字符

时间:2011-07-19 10:12:36

标签: jquery asp.net-mvc fckeditor

我正在使用textarea并在页面加载时使用fck编辑器将其更改为html textbox

var oFCKeditor = new FCKeditor('Simplify');
oFCKeditor.BasePath = "/Content/fckeditor/";
oFCKeditor.Height = 400;oFCKeditor.ReplaceTextarea();

所以,让我知道如何计算该类型的char

1 个答案:

答案 0 :(得分:1)

您可以轻松检索FCKEDitor可编辑区域内的文本,请参阅以下两个文档:

http://docs.cksource.com/CKEditor_3.x/Developers_Guide/Integration

http://docs.cksource.com/CKEditor_3.x/Developers_Guide/jQuery_Adapter

获得textarea的内容后,您可以遍历文本并计算字符,单词,以及字符串。