• FCKeditor文本编辑器使用手册


     

    注意:该文本编辑器有版本差异,.dll文件和所下载的文件夹文件版本需一致
    配置和使用步骤如下:
    1、下载FCKeditor压缩包,解压后将整个fckeditor文件夹拷贝到网站根目录下
    2、下载fckeditor动态链接库文件(.dll文件)FredCK.FCKeditorV2.dll,工具箱中右击选择项,将.dll文件添加到工具箱中
    3、配置一:
    在网站web.config文件中进行如下设置
    <appSettings>
        <add key="FCKeditor:BasePath" value="~/FCKeditor/"/>
        <add key="FCKeditor:UserFilesPath" value="~/UpLoad" />
     </appSettings>
    要求:在网站根目录下有UpLoad文件夹,文件夹下有image文件夹
    4、配置二:
    在fckeditor/editor/fckconfig.js中作如下修改:
    var _FileBrowserLanguage = 'php' ; // asp | aspx | cfm | lasso | perl | php | py
    var _QuickUploadLanguage = 'php' ; // asp | aspx | cfm | lasso | perl | php | py

    修改为:
    var _FileBrowserLanguage = 'aspx' ; // asp | aspx | cfm | lasso | perl | php | py
    var _QuickUploadLanguage = 'aspx' ; // asp | aspx | cfm | lasso | perl | php | py

    默认为php,必须更改。

    6、配置三:
    fckeditor/editor/filemanager/connectors/aspx/config.ascx文件中有一个安全性的验证方法。
    该方法默认如下:
    private bool CheckAuthentication()
     {
      // WARNING : DO NOT simply return "true". By doing so, you are allowing
      // "anyone" to upload and list the files in your server. You must implement
      // some kind of session validation here. Even something very simple as...
      //
      //  return ( Session[ "IsAuthorized" ] != null && (bool)Session[ "IsAuthorized" ] == true );
      //
      // ... where Session[ "IsAuthorized" ] is set to "true" as soon as the
      // user logs in your system.

      return false;
     }
    我们必须做一些修改,最简单的但也是最不安全的方法就是将false强制改为true,但是如果这样做的话安全性事最低的,注释写的很明白:简单的改为true后,谁都可以上传文件。另外一种安全的方法做法就是对上述方法做如下更改:
    private bool CheckAuthentication()
     { 
      return ( Session[ "IsAuthorized" ] != null && (bool)Session[ "IsAuthorized" ] == true );
     }
    但是这样做的话,要在合法用户(如管理员)登录时定义一个session并且赋值为true,如下:Session["IsAuthorized"]=true。
    5、配置四(可选):
    fckeditor/fckconfig.js作如下更改:
    FCKConfig.DefaultLanguage  = 'zh-cn' ;//默认为en英文,更改为中文
    6、配置五(可选):
    fckeditor/fckconfig.js作如下更改:
    FCKConfig.TabSpaces  = 1 ;//默认为0,表示在编辑器中不可以使用Tab键
    7、删除一些不必要的文件(可选):
    fckeditor目录下除editor文件夹、fckconfig.js、fckeditor.js、fckstyles.xml fcktemplates.xml文件外,全部删除。fckeditor/editor/filemanager/connectors/下只保留aspx文件夹,其他的全部删除

    FCKeditor文本编辑器功能很强大,还有很多都可以根据自己的需要改变,但一般上面几步就够我们用了。

    FCKeditor文本剪辑器下载

    0
    0
  • 相关阅读:
    Fragment使用具体解释
    2014百度之星第一题Energy Conversion
    HDU 2602 Bone Collector 0/1背包
    Angular 2 + 折腾记 :(7) 初步了解表单:模板驱动及数据驱动及脱坑要点
    《开源框架那点事儿25》:对框架模板引擎实现方式的改造实录
    ROS机器人程序设计(原书第2版)补充资料 (柒) 第七章 3D建模与仿真 urdf Gazebo V-Rep Webots Morse
    sql改写or 改成union不等价数据变多
    在GDAL中添加GDALRasterizeGeometriesBuf函数
    多时相地图瓦片简单设想
    记录一次使用VS2015编译错误的原因查找(boost+gdal)
  • 原文地址:https://www.cnblogs.com/angells/p/1568596.html
Copyright © 2020-2023  润新知