FCKeditor is an open source project on sourceforge.net. It mainly implements the function of an online web page editor, allowing web programs to have powerful editing functions such as MS Word. The official website is http://www.fckeditor.net, which supports ASP.Net, ASP, ClodFusion, PHP, Java and other languages on the server side, and supports mainstream browsers such as IE 5+, Mozilla, and Netscape. First download fckeditor from the official website. Note that there are two packages, one is the main file and the other is the jsp integration package. 1. Unzip FCKeditor_2.2.zip, (FCKeditor main file), and copy the FCKeditor directory to the root directory of the website. 2. Unzip 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 the two servlet and servlet-mapping definitions in FCKeditor-2.3/web/WEB-INF/web.xml to your own Modify the following contentin the project's web.xml file : |
|
Modification results: |
|
4. Copy the files in the FCKeditor-2.3/web/WEB-INF/lib directory to the lib folder of your own project 5. Add to the jsp interface where FCKeditor needs to be used: // Add // at the beginning of the file // where to use it join in |
|
Start the server test...After success, let's slim down FCKeditor. 1. Delete all folders starting with "_" underscores in the FCKeditor directory and subdirectories. 2. Only fckconfig.js, fckeditor.js will be retained in the FCKeditor root directory. Delete all the rest of fckstyles.xml, fcktemplates.xml 3. Clear the files and folders in the editor/filemanager/upload directory. 4. You can also delete the skin files in the editor/skins directory, leaving only the default set of skins (if You don’t need to change the skin) 5. You can also delete the files in the editor/lang directory and keep only en.js, fcklanguagemanager.js, zh-cn.js, zh.js files (English, simplified Chinese, traditional Chinese should generally be That's enough :) ) Done. Other issues: When used in struts+spring+hibernate, theerror message may appear in the image upload function: The output format must have a '{http://xml.apache.org/xalan}content-handler' property! , delete xalan*.jar in the WEB-INF/lib directory and try security issues: If ordinary users can also use FCKEditor in the front desk, pay attention to related security issues. When using it in the front desk, do not use the default ToolBar, and add The image, flash, and image field buttons are removed. Configuring the values in the array in about 78 lines in fckconfig.js is like a function on the interface. You can forcefully try out what each set of values represents. The installation of FCKeditor is now complete. For detailed configuration, you can see the examples in the web/_samples directory in the FCKeditor-2.3.zip, (jsp, FCKeditor integration package) folder. |