计算机网络/计算机科学与应用/系统/运维/开发

设置ueditor编辑器哪些可以显示的功能哪些不要的功能

var ue = UE.getEditor('container', {
    initialFrameHeight: 400,
    scaleEnabled: true,
    autoHeightEnabled: false,
    toolbars: [[
        'fullscreen',
        'source',
        '|',
        'undo',
        'redo',
        '|',
        'bold',
        'italic',
        'underline',
        'strikethrough',
        '|',
        'forecolor',
        'backcolor',
        '|',
        'paragraph',
        'fontfamily',
        'fontsize',
        '|',
        'justifyleft',
        'justifycenter',
        'justifyright',
        'justifyjustify',
        '|',
        'insertorderedlist',
        'insertunorderedlist',
        '|',
        'link',
        'unlink',
        'simpleupload',
        'insertimage',
        'attachment',
        '|',
        'removeformat',
        'cleardoc',
        'preview'
    ]]
});


功能配置名称
全屏fullscreen
HTML源码source
撤销undo
重做redo
加粗bold
斜体italic
下划线underline
删除线strikethrough
字体颜色forecolor
背景颜色backcolor
段落格式paragraph
字体fontfamily
字号fontsize
左对齐justifyleft
居中justifycenter
右对齐justifyright
两端对齐justifyjustify
有序列表insertorderedlist
无序列表insertunorderedlist
超链接link
取消链接unlink
单图上传simpleupload
多图上传insertimage
编辑器附件attachment
表格inserttable
删除表格deletetable
清除格式removeformat
清空文档cleardoc
预览preview
打印print

不建议给普通通知开放:

  • source:可直接输入HTML。

  • insertvideomusic:可能嵌入外部内容。

  • insertframe:可能嵌入第三方网页。

  • webappmapgmap

  • attachment:因为页面已经单独实现多附件上传。

  • snapscreen:依赖额外的截图组件。

  • print:后台一般不需要。

  • cleardoc:容易误清空内容。


世上最好的保鲜就是不断进步,让自己成为一个更好和更值得爱的人。

评论

^