Drupal7 安装 CKEditor 和 IMCE 模块 及配置

Drupal7 安装 CKEditor 编辑器的方法及配置:
  1. 首先要下载模块和编辑器
    CKEditor Moudle: http://drupal.org/project/ckeditor
    IMCE Module: http://drupal.org/project/imce
    CKEditor 编辑器: http://ckeditor.com/download
  2. 安装 CKEditor MoudleIMCE Moudle
    将解压的 CKEditor Moudle 和 IMCE Moudle 模块分别放到
    sites/all/moudles/ckeditor/
    sites/all/moudles/imce/
    然后将 CKEditor 编辑器压缩包里面的放到 /sites/all/moudles/ckeditor/ckeditor/中, 如下图
    CKEditor
    放好后的路径如:
    /sites/all/moudles/ckeditor/ckeditor/ckeditor.config.js
    /sites/all/moudles/ckeditor/ckeditor/ckeditor_php5.php
    /sites/all/moudles/ckeditor/ckeditor/ckeditor_php4.php
    /sites/all/moudles/ckeditor/ckeditor/ckeditor/plugins/*
    /sites/all/moudles/ckeditor/ckeditor/ckeditor/_samples/*
    /sites/all/moudles/ckeditor/ckeditor/ckeditor/_source/*
    /sites/all/modules/imce/css/*
  3. 在 Modules 中启用 CKEditor 和 ICME 这两个模块.
  4. Home » Administration » Configuration » Content authoring 中配置CKEditor ( 路径为 /admin/config/content/ckeditor)
    选择 Full HTMLedit Operations 进入 CKEditor 配置. ( 路径为 /admin/config/content/ckeditor/edit/Full )
    然后点击 EDITOR APPEARANCE 选项进去, 在显示的表单中有个Toolbar, 这个是配置CKEditor显示哪些操作标签的.
    在默认的这行 ['Image','Media','Flash','Table','HorizontalRule','Smiley','SpecialChar'], 中添加一个 ‘IMCE‘ 这样才能在编辑器里显示 IMCE上传图片的图标.
    添加后为: ['Image','IMCE','Media','Flash','Table','HorizontalRule','Smiley','SpecialChar'],
    接着在 Plugins 中选中 IMCE Window button in toolbar
    Toolbar CKEditor

    最后在 File browser settings 中的
    File browser type (Link dialog)
    File browser type (Image dialog)
    File browser type (Flash dialog)
    三个选项都选择IMCE, 如下图
    File browser settings

  5. OK, 配置完毕, 在 add Content 时选择 FULL HTML就行了.
    另外也可以配置 Filtered HTML, 在 Toolbar配置里面设置一下, 比如我的设置如下
    1
    2
    3
    4
    5
    6
    7
    [
    ['Source'],
    ['Cut','Copy','Paste','PasteText','Undo','Redo'],
    ['Bold','Italic','Underline','Strike','-'],
    ['NumberedList','BulletedList','-','Outdent','Indent','Blockquote'],
    ['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
    ]

    显示在 Filtered HTML 的效果为:
    Filtered HTML


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值