现在的位置: 网页制作教程网站制作经验 >正文
建站工具

fckeditor编辑器里如何取消源代码的按钮

发表于2016/11/24 网站制作经验 0条评论 ⁄ 热度 2,418℃

我们的网站一般需要集成编辑器,但如果在会员区往往只需要简易的编辑器,往往会要去掉很多不想关的按钮,比如源代码一般都是要取消掉的。

源代码按钮

今天我们以fckeditor编辑器为例,讲如何取消掉源代码按钮

首先我们在配置文件里找到下面一段代码:

FCKConfig.ToolbarSets["Default"] = [
 ['Source','-','Save','Preview'],
 ['Cut','Copy','Paste','PasteText','PasteWord'],
 ['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
 ['TextColor','BGColor'],
 ['Link','Unlink','-','Image','Flash','Table','Rule','Smiley','SpecialChar'],
 ['ShowBlocks'],
 '/',
 ['FontFormat','FontName','FontSize'],
 ['Bold','Italic','Underline','StrikeThrough','Substyle','Superstyle'],
 ['OrderedList','UnorderedList','-','Outdent','Indent','Blockquote'],
 ['JustifyLeft','JustifyCenter','JustifyRight','JustifyFull','FitWindow']
] ;

上方的'Source'对应的就是源代码按钮,直接删除。

  • 暂无评论