<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    下載

    FCKeditor的官方站點http://www.fckeditor.net/download上下載FCKeditor 2.3.2和FCKeditor.Java,其中FCKeditor 2.3.2是源碼,F(xiàn)CKeditor.Java是在jsp中使用的例程。

    ?

    瘦身

    FCKeditor 2.3.2解壓到FCKeditor文件夾,然后刪除如下文件或目錄:

    1、/_samples,/_testcases;

    2、刪除/_documentation.html,_whatsnew.html,fckeditor.afp,fckeditor.asp,fckeditor.cfc,fckeditor.cfm,
    fckeditor.lasso,fckeditor.php,fckeditor.pl,fckeditor.py
    只剩下fckconfig.js,fckeditor.js,fckstyles.xml,fcktemplates.xml,htaccess.txt,license.txt;

    3、/editor/_source;

    4、/editor/filemanager/browser/default/connectors;

    5、/editor/filemanager/upload;

    6、語言包/editor/lang中只留下en.js、zh-cn.js;

    哈哈,一下子從2.5M瘦到832K,爽呀!還可以在皮膚包里/editor/skins動動腦筋,比如只留一個sliver,這個好配色。

    配置

    FCKeditor的jsp中使用的例程和FCKeditor源碼結(jié)合起來,解壓FCKeditor.Java,將解壓文件夾中web目錄下的所有文件拷貝到FCKeditor目錄中,這樣在FCKeditor目錄多了兩個目錄:

    ├─_samples

    ? ? index.jsp

    ? ? sample.css

    ? ? sampleslist.jsp

    ? ?

    ? └─jsp

    ????????? sample01.jsp

    ????????? sample02.jsp

    ????????? sample03.jsp

    ????????? sample04.jsp

    ????????? sample05.jsp

    ????????? sample06.config.js

    ????????? sample06.jsp

    ????????? sample07.jsp

    ????????? sampleposteddata.jsp

    ?????????

    └─WEB-INF

    ??? ? web.xml

    ??? ?

    ??? └─lib

    ??????????? FCKeditor-2.3.jar

    ??????????? commons-fileupload.jar

    看一下web.xml文件,里面增加了文件瀏覽和文件上傳得servlet。

    l???????? 修改文件FCKeditor/fckconfig.js

    1、? 修改屬性

    中文:FCKConfig.DefaultLanguage???? = 'zh-cn' ;

    皮膚:FCKConfig.SkinPath = FCKConfig.BasePath + 'skins/default/' ;

    2、? 使用servlet做文件瀏覽和上傳

    參考http://wiki.fckeditor.net/Developer%27s_Guide/Integration/Java

    //browser

    FCKConfig.LinkBrowserURL = FCKConfig.BasePath + "filemanager/browser/default/browser.html?Connector=connectors/jsp/connector" ;

    FCKConfig.ImageBrowserURL = FCKConfig.BasePath + "filemanager/browser/default/browser.html?Type=Image&Connector=connectors/jsp/connector" ;

    FCKConfig.FlashBrowserURL = FCKConfig.BasePath + "filemanager/browser/default/browser.html?Type=Flash&Connector=connectors/jsp/connector" ;

    ?

    //upload

    FCKConfig.LinkUploadURL = FCKConfig.BasePath + 'filemanager/upload/simpleuploader?Type=File' ;

    FCKConfig.FlashUploadURL = FCKConfig.BasePath + 'filemanager/upload/simpleuploader?Type=Flash' ;

    FCKConfig.ImageUploadURL = FCKConfig.BasePath + 'filemanager/upload/simpleuploader?Type=Image' ;

    l???????? 修改web.xml增加FCKeditor的taglib

    FCKeditor.Java解壓目錄/src目錄下拷貝FCKeditor.tld文件到WEB-INF目錄下,在web.xml文件中增加:

    <taglib>

    ??? <taglib-uri>/WEB-INF/FCKeditor.tld</taglib-uri>

    ??? <taglib-location>/WEB-INF/FCKeditor.tld</taglib-location>

    </taglib>

    ?

    使用

    jsp 頁面中作如下調(diào)用(具體如何使用可以看 FCKeditor.tld定義 ):

    ...

    ?

    <%@ taglib uri="/WEB-INF/FCKeditor.tld" prefix="FCK" %>

    ?

    ...

    ?

    <FCK:editor id="EditorDefault" basePath="/FCKeditor/">

    This is FCKeditor demo!

    </FCK:editor>

    ?

    ...

    運行例程

    將我們修改了半天的整個 FCKeditor目錄拷貝到tomcat5.0.28(或其他web服務(wù)器)的webapps目錄下,啟動tomcat訪問http://localhost:8080/FCKeditor/_samples/ 試用一下FCKeditor 2.3.2的強大功能,有了demo在項目中如何使用,你自己琢磨吧!

    ?

    例程下載: FCKeditor

    posted on 2006-11-03 11:00 野草 閱讀(2593) 評論(2)  編輯  收藏 所屬分類: 2shtv

    評論:
    # re: 在jsp中使用fckeditor 2.3 2007-06-22 16:48 | gostseraph
    QQ122767028
    你的例子連數(shù)據(jù)庫嗎
      回復(fù)  更多評論
      
    # re: 在jsp中使用fckeditor 2.3 2007-06-22 16:53 | gostseraph
    你的例子怎么運行啊 ,老跳出登陸頁面
      回復(fù)  更多評論
      
    主站蜘蛛池模板: 亚洲AV成人无码网站| 一区二区三区无码视频免费福利| 91精品啪在线观看国产线免费| 免费乱码中文字幕网站| 亚洲日本国产乱码va在线观看| 国产大片免费天天看| 午夜高清免费在线观看| 久久精品国产亚洲AV大全| 久久国产精品免费| 日本免费v片一二三区| 亚洲一区二区久久| 久久免费看少妇高潮V片特黄| 亚洲精品无码久久不卡| 国产 亚洲 中文在线 字幕| 久视频精品免费观看99| 亚洲国产综合无码一区| 黄色a级免费网站| 麻豆国产入口在线观看免费| 亚洲狠狠狠一区二区三区| 中文字幕在线免费看线人| 亚洲国产一成久久精品国产成人综合| 亚洲中文字幕一区精品自拍| 4399好看日本在线电影免费| 亚洲VA成无码人在线观看天堂| A毛片毛片看免费| 亚洲国产精品碰碰| 黄色三级三级三级免费看| 午夜视频免费观看| 最新国产成人亚洲精品影院| xxxx日本免费| 久久精品蜜芽亚洲国产AV| 久久久久国产精品免费免费不卡| 亚洲日韩欧洲乱码AV夜夜摸| 一级毛片a免费播放王色| 亚洲av无码成人精品区| 国产成人久久精品亚洲小说| 国产大片91精品免费观看男同 | 国产大片91精品免费观看不卡| 亚洲精品国产成人99久久| a级毛片免费完整视频| 亚洲色成人网站WWW永久|