ckeditor自定义工具栏
2024-08-26 21:32:45
/**
* 获取编辑器工具栏自定义参数
* @param type 类型 simple=极简版 basic=基本版 full=完整版
*/
function get_ckeditor_toolbar(type) {
if(!arguments[0]) type = 'simple';
//完整版
var ckeditor_toolbar_full =
[
['Maximize','Autoformat','NewPage','Source','Print'],
['PasteText','PasteFromWord','Replace'],
['Form','Checkbox','Radio','TextField','Textarea','Select','Button','ImageButton','HiddenField'],
['RemoveFormat','Bold','Italic','Underline','Strike','Subscript','Superscript'],
['Link','Unlink','-','TextColor','BGColor'],
['NumberedList','BulletedList','Outdent','Indent','-','Blockquote','CreateDiv','-','JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['upfile','Image','CodeSnippet','Flash','Table','HorizontalRule','SpecialChar','PageBreak','Iframe'],
['Styles'],
['Format'],
['Font'],
['FontSize'],
];
if(type == 'full') return ckeditor_toolbar_full;
//基本版
var ckeditor_toolbar_basic =
[
['Maximize','Autoformat','NewPage','Source','Print'],
['PasteText','PasteFromWord','Replace'],
['RemoveFormat','Bold','Italic','Underline','Strike','Subscript','Superscript'],
['Link','Unlink','-','TextColor','BGColor'],
['NumberedList','BulletedList','Outdent','Indent','-','Blockquote','CreateDiv','-','JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['upfile','Image','CodeSnippet','Flash','Table','HorizontalRule','SpecialChar','PageBreak','Iframe'],
['Format'],
['Font'],
['FontSize'],
];
if(type == 'basic') return ckeditor_toolbar_basic;
//极简版
var ckeditor_toolbar_simple =
[
['Maximize','Autoformat','NewPage','Source','Print'],
['PasteText','PasteFromWord','Replace'],
['RemoveFormat','Bold','Italic'],
['Link','Unlink','-','TextColor','BGColor'],
['NumberedList','BulletedList','Outdent','Indent','-','JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['upfile','Image','Flash','Table','HorizontalRule'],
['Format'],
['FontSize'],
];
if(type == 'simple') return ckeditor_toolbar_simple;
} // end func
本人当时使用的编辑器:ckeditor_4.4.6_full
最新文章
- 【JavaScript】获取未知类的结构
- github之git基本命令介绍的简单整理
- Eclipse如何解决启动慢
- Mac Pro 安装 最新版的 SVN 1.9.4
- MySQL5.5 RPM安装的默认安装路径
- Android Studio调试功能使用总结
- 原始ajax发起请求并反馈
- 开源的rtsp实现
- 复制带有random指针的单链表
- maven使用.02.一些概念
- django安装配置及测试
- 201521123118《java程序与设计》第8周学习总结
- HDFS概述(1)————HDFS架构
- ssm搭建报错
- jQuery_事件学习
- better-scroll不能滚动之 滚动监听-左右联动
- C++输出二进制文件和文本文件
- Kubernetes系列02—Kubernetes设计架构和设计理念
- 小问题填坑,关于obj.x和obj[";x";]
- dependency walker检查dll依赖关系目录设置的问题
热门文章
- Linux下OpenSSL加密解密压缩文件(AES加密压缩文件)
- 翻译-在10行代码之内创建容器化的.net core应用
- Go part 6 接口,接口排序,接口嵌套组合,接口与类型转换,接口断言
- robot framework 怎么验证搜索无记录,页面元素不存在
- 理解Java序列化中的SerialVersionUid
- 【转载】Sqlserver中使用Round函数对计算结果四舍五入
- nginx关闭日志功能access_log关闭
- select加锁分析(Mysql)
- ORA-03113:通信通道的文件结尾 解决办法
- 二叉树遍历(非递归版)——python