读取CKEditor的值(包括纯文本)
来源:互联网 发布:安芬尼.哈达威数据 编辑:程序博客网 时间:2024/05/22 14:02
1、获取CKEditor被选中的内容
var mySelection = CKEDITOR.instances.ckStem.getSelection();
if (CKEDITOR.env.ie) {
mySelection.unlock(true);
data = mySelection.getNative().createRange().text;
} else {
data = mySelection.getNative();
}
2、获取CKEditor纯文本
var stemTxt=CKEDITOR.instances.CKEditor1.document.getBody().getText(); //取得纯文本
3、获取CKEditor带HTML标签的文本
var stem = CKEDITOR.instances.CKEditor1.getData();
var mySelection = CKEDITOR.instances.ckStem.getSelection();
if (CKEDITOR.env.ie) {
mySelection.unlock(true);
data = mySelection.getNative().createRange().text;
} else {
data = mySelection.getNative();
}
2、获取CKEditor纯文本
var stemTxt=CKEDITOR.instances.CKEditor1.document.getBody().getText(); //取得纯文本
3、获取CKEditor带HTML标签的文本
var stem = CKEDITOR.instances.CKEditor1.getData();
0 0
- 读取CKEditor的值(包括纯文本)
- 读取CKEditor的值(包括纯文本)
- 『实践』获取CKEditor的html文本、纯文本、被选中的内容及赋值
- js获取文本编译器CKEditor的值
- 纯文本的威力
- Matlab读取纯文本光谱文件
- [IO]——纯文本读取
- 很棒的富文本编辑器CKEditor
- 在线网页文本编辑器ckeditor的使用
- 富文本编辑器ckeditor的使用
- ckeditor富文本编辑器的使用
- Ckeditor一种很方便的文本编辑器
- 富文本编辑器 CKeditor 的使用
- 前端富文本编辑器ckeditor的使用
- 页面文本编辑器 ckeditor的使用
- 富文本编辑器CKEditor的使用
- CKeditor富文本编辑器的使用
- python网络爬虫文档读取-纯文本读取
- 图像滤镜艺术--暴雨滤镜
- css语法--选择器
- HTTP协议 (四) 缓存
- C++内存分配方式详解——堆、栈、自由存储区、全局/静态存储区和常量存储区
- 【技巧】---质因子分解法
- 读取CKEditor的值(包括纯文本)
- CentOS 6.4 安装 nginx + php-fpm
- HTTP协议 (五) 代理
- mac os 安装Myeclipse错误: Your system does not have sufficient memory to support MyEclipse
- robot.txt 搜索引擎 蜘蛛爬虫 搜索规则
- HTTP协议 (七) Cookie
- C++和java字节
- HDU 2028 Lowest Common Multiple Plus
- Android开发之来电电话挂断实现