FCKeditor is an open source project above SourceForge.net, which implements the functions of the Online Web page editor, allowing web programs to have powerful editing capabilities such as MS Word. The official website is http://www.fckeditor.net, support asp.net, ASP, clodfusion, PHP, Java and other languages on the server side, and support the mainstream browser such as IE 5+, Mozilla, Netscape.
First in the official website download FCKeditor, note that there are two packages, one is the main file, one is the JSP integration package.
1, decompression Fckeditor_2.2.zip, (fckeditor main file), the FCKeditor directory copied to the site root directory,
2, Decompression Fckeditor-2.3.zip, (Jsp,fckeditor integration package), function: This is the JSP integration pack for using FCKeditor inside a Java server page Without the complexity of using a Java scriptlets or the JavaScript API.
3. Copy two servlet,servlet-mapping definitions from fckeditor-2.3/web/web-inf/web.xml to web.xml files from the project
Modify the following:
<servlet-mapping>
<servlet-name>Connector</servlet-name>
<url-pattern>
/ Editor/filemanager/browser/default/connectors/jsp/connector
</url-pattern>
</servlet-mapping >
<servlet-mapping>
<servlet-name>SimpleUploader</servlet-name>
< Url-pattern>/editor/filemanager/upload/simpleuploader</url-pattern>
</servlet-mapping>
Modify Result:
<servlet-mapping>
<servlet-name>Connector</servlet-name>
<url-pattern>
/ Fckeditor/editor/filemanager/browser/default/connectors/jsp/connector
</url-pattern>
</ servlet-mapping>
<servlet-mapping>
<servlet-name>SimpleUploader</servlet-name>
<url-pattern>/FCKeditor/editor/filemanager/upload/simpleuploader</url-pattern>
</ Servlet-mapping>
4. Copy the files in the Fckeditor-2.3/web/web-inf/lib directory to the Lib folder of your own project
5, in the need to use FCKeditor JSP interface to add:
Add at the beginning of the file
<%@ taglib uri= "Http://fckeditor.net/tags-fckeditor" prefix= "FCK"%>
To use the place to join
<fck:editor id= "content" basepath= "/fckeditor/" ima
Gebrowserurl= "/fckeditor/editor/filemanager/browser/default/browser.html?" Type=image&connector=connectors/jsp/connector "Linkbrowserur l="/fckeditor/editor/filemanager/browser/ Default/browser.html? Connector=connectors/jsp/connector "Flashbrowserurl="/fckeditor/editor/filemanager/browser/default/browser.html ? Type=flash&connector=connectors/jsp/connector "Imageuploadurl="/fckeditor/editor/filemanager/upload/ Simpleuploader? Type=image "Linkuploadurl="/fckeditor/editor/filemanager/upload/simpleuploader? Type=file "Flashuploadurl="/fckeditor/editor/filemanager/upload/simpleuploader? Type=flash ' > This is default content:) </fck:editor>
&NBSP
Start server test ... After success, to give FCKeditor thin body.
1, delete all folders in the FCKeditor directory and subdirectories under the "_" Underline
The 2.FCKeditor root directory only retains fckconfig.js, Fckeditor.js, FckstYles.xml, fcktemplates.xml all the rest delete
3. The files and folders in the Editor/filemanager/upload directory are emptied.
4. You can also delete the skin files in the Editor/skins directory, leaving only a default set of skins (if you don't need to change your skin)
5. Can also delete the Editor/lang directory files, only retain En.js, Fcklanguagemanager.js, Zh-cn.js, zh.js files (English, Simplified Chinese, traditional Chinese should generally be enough:)
completes.
Other issues:
Used in struts+spring+hibernate, the upload image feature may appear in the report:
The output format must have a ' {http://xml.apache.org/xalan}content-handler ' property!
Wrong case, Xalan*.jar delete web-inf/lib directory to try
Security issues:
If in front of the ordinary users can also use FCKeditor, to pay attention to related security issues, in the foreground use, do not use the default toolbar, to add images, flash, image domain button removed, in the fckconfig.js about 78 rows of configuration The values in those arrays are like a function on the interface, you can force each set of values to try to represent what.
is complete with this installation FCKeditor, and detailed configuration you can see the example in the Web/_samples directory in Fckeditor-2.3.zip, (jsp,fckeditor consolidation Package) folder.