FCKeditor2.4.1 For Java使用1(下载,配置,演示)

我的环境及开发工具:jdk1.6.0_10+tomcat6.0+myeclipse6.5

1. FCKeditor简介:
      FCKeditor是一个专门使用在网页上属于开放源代码的所见即所得文字编辑器。它志于轻量化,不需要太复杂的安装步骤即可使用。它可和PHP、JavaScript、ASP、ASP.NET、ColdFusion、Java、以及ABAP等不同的编程语言相结合。“FCKeditor”名称中的“FCK” 是这个编辑器的作者的名字Frederico Caldeira Knabben的缩写。FCKeditor 相容于绝大部分的网页浏览器。

2. 下载地址:

下载页面:
             http://sourceforge.net/project/showfiles.php?group_id=75348&package_id=129511
fckeditor-java-2.4.1-bin.zip
             http://switch.dl.sourceforge.net/sourceforge/fckeditor/fckeditor-java-2.4.1-bin.zip
FCKeditor_2.6.4.zip
             http://jaist.dl.sourceforge.net/sourceforge/fckeditor/FCKeditor_2.6.4.zip
fckeditor-java-demo-2.4.1.war
             http://nchc.dl.sourceforge.net/sourceforge/fckeditor/fckeditor-java-demo-2.4.1.war
fckeditor-java-2.4.1-src.zip
             http://jaist.dl.sourceforge.net/sourceforge/fckeditor/fckeditor-java-2.4.1-src.zip

在你的Java Web 项目中用,只要下载fckeditor-java-2.4.1-bin.zip(含Jar包)和fckeditor-java-demo-2.4.1.war(fckeditor文件夹),把fckeditor-java-core-2.4.1.jar粘贴到lib目录下,把fckeditor文件夹放到项目中(比如根目录)

再加上这几个jar包:

fckeditor需要的jar包

3. web.xml配置:

加上:

<servlet>
	<servlet-name>Connector</servlet-name>
	<servlet-class>net.fckeditor.connector.ConnectorServlet</servlet-class>
	<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>   
   	<servlet-name>Connector</servlet-name>
   	<url-pattern>/fckeditor/editor/filemanager/connectors/*</url-pattern>   
</servlet-mapping>

4.在项目的src下建立fckeditor.properties 文件,添加以下代码:

    connector.userActionImpl=net.fckeditor.requestcycle.impl.UserActionImpl

5. 测试:

test.jsp:

<%@ taglib uri="http://java.fckeditor.net" prefix="FCK" %>


<body style="text-align: center;">    
	<div style="text-align: center;width: 600pt">    
	<h2>FckEditor测试</h2>    
	<hr>
	<form action="show.jsp" method="post">    
    	<FCK:editor instanceName="content" height="300px">    		
		</FCK:editor>		   
   		<input type="submit" value="提交"/>    
   		<input type="reset" value="重置"/>    
   	</form>    
	</div>    
  </body>

 

show.jsp:

<body>
    
	${param.content}

  </body>

 

————————————————————————The End——————————————————————————

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值