FCKeditor在线编辑器的使用


一、使用说明:

参考http://doodoo.blog.enorth.com.cn/article/126662.shtml文档,不过好像很简单。主要步骤:

1、下载:下载地址:http://sourceforge.net/project/showfiles.php?group_id=75348&package_id=75845
我用的是最新版FCKeditor_2.3.2.zip(包含editor和配置信息在里面)和FCKeditor_2.3.zip(包含jar包和tld文件,web.xml文件),

1、在tomcat的webapp下建立FCKeditor文件夹,将FCKeditor_2.3.zip解压后的web文件夹中内容拷贝(包括_simples和WEB-INF两个文件夹),将src下的FCKeditor.tld拷贝到tomcat/webapp/FCKeditor/WEB-INF下。

2、将FCKeditor_2.3.2.zip解压后里面的editor文件夹和fckconfig.js,fckeditor.js,fckstyles.xml,fcktemplates.xml四个文件拷贝到tomcat/webapp/FCKeditor下面。

3、修改web.xml,添加

   
        /TestFCKeditor
        /WEB-INF/FCKeditor.tld
   

通过上面三步,即完成下载和配置,

访问:http://localhost:8080/FCKeditor/_samples/index.jsp,即可看到效果。

/*--------------------------------------------------------------------------------------*/

二、心得(from:http://mylog.lib.whpu.edu.cn/blogview.asp?logID=100)

1、把所有配置文件集中在editor文件下,有利于管理。

及把原fckeditor 下文件(fckconfig.js、fckeditor.js、fckeditor.asp、fckstyles.xml、fcktemplates.xml)copy到editor 下。
1、需要修改editor/jsfck_startup.js ,搜索

程序代码:

FCKScriptLoader.AddScript('../fckconfig.js')
 改为
程序代码:
FCKScriptLoader.AddScript('fckconfig.js')
 说明'fckconfig.js'与fckeditor.html 在同一目录
2、修改fckconfig.js'
增加
程序代码:
FCKConfig.BasePath="/../editor/"

程序代码:
FCKConfig.StylesXmlPath        = FCKConfig.EditorPath + 'fckstyles.xml' ;
FCKConfig.TemplatesXmlPath    = FCKConfig.EditorPath + 'fcktemplates.xml' ;

程序代码:
FCKConfig.StylesXmlPath        = FCKConfig.EditorPath + 'editor/fckstyles.xml' ;
FCKConfig.TemplatesXmlPath    = FCKConfig.EditorPath + 'editor/fcktemplates.xml' ;

程序代码:
FCKConfig.StylesXmlPath        = FCKConfig.BasePath + 'fckstyles.xml' ;
FCKConfig.TemplatesXmlPath    = FCKConfig.BasePath + 'fcktemplates.xml' ;

/*---------------------------------------------------------------------------------*/

在jsp使用FCKEditor浏览服务器图片时错误:XML request error: Internal Server Error(500)
我的这个错误的原因:没有xml解析器。
解决方法如下:
http://apache.justdn.org/xml/xalan-j/binaries/
下载 xalan-j_2_7_0-bin-2jars.zip
解压后把 xalan.jar,serializer.jar拷贝到应用的lib目录下,ok。
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值