[原創][多圖]在線編輯器FCKeditor 2.0試用小記

發表于:2007-05-25來源:作者:點擊數: 標簽:多圖原創在線編輯器FCKeditor
[b:513b29f04f]一、簡介[/b:513b29f04f] 2004年11月30日推出了FCKeditor2.0RC1版,據其官方網站稱:這是FCKeditor2.0版的第一個穩定版本。大家現在可以考慮正式使用它了。目前支持的后臺語言有ASP、ASP.Net、 PHP 和ColdFusion。 筆者在經過簡單的試用發現,

[b:513b29f04f]一、簡介[/b:513b29f04f]
    2004年11月30日推出了FCKeditor 2.0 RC1版,據其官方網站稱:這是FCKeditor 2.0版的第一個穩定版本。大家現在可以考慮正式使用它了。目前支持的后臺語言有ASP、ASP.Net、PHP和ColdFusion。
    筆者在經過簡單的試用發現,2.0版確實比1.6版有了許多的改進。首先是FCKeditor的文件結構更加清晰,可以更方便地將其部署在自己的系統中。另外2.0版終于支持了Firefox 1.0瀏覽器,這將為FCKeditor贏得更多的使用者。廢話不多說,讓我們趕快來學習如何安裝、配置FCKeditor 2.0吧。
[b:513b29f04f]二、安裝與范例[/b:513b29f04f]
    首先到[url]http://sourceforge.net/projects/fckeditor/ [/url]下載FCKeditor 2.0 RC1(554K),并將其解壓縮到你的網站目錄里面,并將文件夾名改為FCKeditor。舉例來說,如果你的網站放在shaof這個目錄下面,則在這個目錄中建立3個子目錄:
FCKeditor:存放從網站上下載的FCKeditor
upimages:用于存放上傳的圖片
admin:里面存放測試頁面
網站的結構如下:
/shaof
   /FCKeditor           //FCKeditor目錄
   /UserFiles            //上傳文件目錄
   /admin
test.php          //提交數據頁面
testsubmit.php     //顯示數據頁面

    進入到FCKeditor目錄下,打開_samples目錄,里面含有各種編程語言調用FCKeditor的范例程序頁面,其中php目錄中包含著一些使用PHP來調用FCKeditor的范例,大家可以看一下,了解FCKeditord的調用方法,下面是我簡寫了一個test.php程序,放在網站根目錄下的admin目錄中:
<?php
if($_POST["ADD"]){
$Content=$_POST['EditorDefault'];
echo $Content;
//變量$Content就是我們在FCKeditord里面編輯的內容,這里可以將其保存到數據庫,代碼省略。
}
?>
<html>
<head>
</head>
<body>
<form action="<?php  echo $_SERVER['PHP_SELF'];  ?>"  method="post" language="javascript">
<?php
//引入在線編輯器
include("../FCKeditor/fckeditor.php") ;

    這里我們先看一下調用FCKeditor的函數,2.0版的調用方式與1.6版變化不大,如果你以前安裝過FCKeditor 1.6,那么只需要修改很少的代碼升級到2.0。
FCKeditor( instanceName[, width, height, toolbarSet, value] )
引用值           含義
InstanceName 實例化編輯器所需的唯一名稱
Width                 編輯器的寬度,單位為象素或者百分比(可選擇的,默認為:100%)
Height                 編輯器的高度,單位為象素或者百分比(可選擇的,默認為:200)
ToolbarSet 工具欄的名稱(可選擇的,默認為:Default)
Value                 編輯器的內容(HTML)初始值(可選擇的)
好啦,下面就讓我們利用這個函數來定制FCKeditor吧。

$oFCKeditor = new FCKeditor('FCKeditor1')  ;
$oFCKeditor->BasePath = '../FCKeditor/' ;
$oFCKeditor->ToolbarSet = 'Default' ;
$oFCKeditor->InstanceName = 'EditorDefault' ;
$oFCKeditor->Width = '100%' ;
$oFCKeditor->Height = '400' ;
$oFCKeditor->Create() ;
?>
<INPUT type="submit" name="ADD" value="提交">
</form>
</body>
</html>

[b:513b29f04f]三、配置[/b:513b29f04f]
FCKeditor 2.0的配置文件為FCKeditor\fckconfig.js,其中幾個重要的配置項目如下:
[b:513b29f04f]1、工具欄的設置[/b:513b29f04f]
    默認情況下,FCKeditor會調用如下的工具欄按鈕,大家可以根據自己的需要進行增減。需要注意的是,2.0版與1.6版的按鈕并不完全相同,有些按鈕以及刪除或者改名了。
//##
//## Toolbar Buttons Sets
//##
FCKConfig.ToolbarSets["Default"] = [
['Source','-','Save','NewPage','Preview'],
['Cut','Copy','Paste','PasteText','PasteWord','-','Print'],
['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
['Bold','Italic','Underline','StrikeThrough','-','Subscript','Superscript'],
['OrderedList','UnorderedList','-','Outdent','Indent'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyFull'],
['Link','Unlink'],
['Image','Table','Rule','SpecialChar','Smiley'],
['Style','FontFormat','FontName','FontSize'],
['TextColor','BGColor'],
['About']
] ;

[b:513b29f04f]2、簡體中文設置[/b:513b29f04f]
編輯edit/lang/fcklanguagemanager.js
將下面語句
FCKLanguageManager.AvailableLanguages = 
{
 'ar'  : 'Arabic',
 'bs'  : 'Bosnian',
 'ca'  : 'Catalan',
 'en'  : 'English',
 'es'  : 'Spanish',
 'et'  : 'Estonian',
 'fi'  : 'Finnish',
 'fr'  : 'French',
 'gr'  : 'Greek',
 'he'  : 'Hebrew',
 'hr'  : 'Croatian',
 'it'  : 'Italian',
 'ko'  : 'Korean',
 'lt'  : 'Lithuanian',
 'no'  : 'Norwegian',
 'pl'  : 'Polish',
 'sr'  : 'Serbian (Cyrillic)',
 'sr-latn' : 'Serbian (Latin)',
 'sv'  : 'Swedish'
}
添加一行 'zh-cn'    : 'Chinese' 從而變成
FCKLanguageManager.AvailableLanguages = 
{
 'ar'  : 'Arabic',
 'bs'  : 'Bosnian',
 'ca'  : 'Catalan',
 'en'  : 'English',
 'es'  : 'Spanish',
 'et'  : 'Estonian',
 'fi'  : 'Finnish',
 'fr'  : 'French',
 'gr'  : 'Greek',
 'he'  : 'Hebrew',
 'hr'  : 'Croatian',
 'it'  : 'Italian',
 'ko'  : 'Korean',
 'lt'  : 'Lithuanian',
 'no'  : 'Norwegian',
 'pl'  : 'Polish',
 'sr'  : 'Serbian (Cyrillic)',
 'sr-latn' : 'Serbian (Latin)',
 'sv'  : 'Swedish',
 'zh-cn'     : 'Chinese'
}
    然后到這里http://www.shaof.com/download/zh-cn.js下載漢化好的zh-cn.js保存到editor/lang目錄下即可。

[b:513b29f04f]四、設置文件上傳[/b:513b29f04f]
    FCKeditor 2.0采用了一種名為“Connector”(連接器)的技術來實現對文件的瀏覽以及上傳。下圖顯示了文件瀏覽的工作流程圖。
 
[b:513b29f04f]圖1:Connector的工作流程圖[/b:513b29f04f]
    從圖中可以看出,當客戶端向服務器發出一個文件操作請求后,Connector就會對此請求進行響應,在服務器的文件系統中進行執行操作,如:文件和文件夾的瀏覽以及創建操作。最后將結果以XML的格式回應給客戶端。具體的技術細節大家可以閱讀FCKeditor自帶的說明指南。
落實到應用,首先我們要選擇一個后臺語言用來實現這個功能,這里我們以PHP為例進行說明。
1、修改配置文件FCKeditor\fckconfig.js中的兩段內容
//Link Browsing
FCKConfig.LinkBrowser = true ;
FCKConfig.LinkBrowserURL = FCKConfig.BasePath + "filemanager/browser/default/browser.html?Connector=connectors/php/connector.php" ;
FCKConfig.LinkBrowserWindowWidth = screen.width * 0.7 ; // 70%
FCKConfig.LinkBrowserWindowHeight = screen.height * 0.7 ; // 70%

//Image Browsing
FCKConfig.ImageBrowser = true ;
FCKConfig.ImageBrowserURL = FCKConfig.BasePath + "filemanager/browser/default/browser.html?Type=Image&Connector=connectors/php/connector.php" ;
FCKConfig.ImageBrowserWindowWidth  = screen.width * 0.7 ; // 70% ;
FCKConfig.ImageBrowserWindowHeight = screen.height * 0.7 ; // 70% ;

2、修改配置文件FCKeditor\editor\filemanager\browser\default\connectors\php\connector.php
// Get the "UserFiles" path.
$GLOBALS["UserFilesPath"] = '/UserFiles/' ;
UserFiles為文件上傳的路徑,與本文開頭所給的例子相對應,大家可以自行修改。

    好啦,只需要兩步就完成了文件上傳的配置工作,真是簡單呀。以后我們通過FCKeditor上傳的文件都會保存在網站的UserFiles目錄下。
 
[b:513b29f04f]圖2:FCKeditor2.0的文件管理截圖[/b:513b29f04f]

[b:513b29f04f]五、結束[/b:513b29f04f]
    最后大家可以把FCKeditor目錄下的_docs和_samples兩個目錄刪除以節省空間。本文是筆者以前寫過的一篇名為《在線編輯器FCKeditor在PHP中的使用方法》(1.6版)文章的升級版本,文章如有不妥之處,還請大家指正。



圖2:FCKeditor2.0的文件管理截圖




圖1:Connector的工作流程圖


 水若寒 回復于:2004-12-05 11:08:21
很好,試驗中....

 xmlv 回復于:2004-12-06 10:29:29
不錯

 tjyihui 回復于:2004-12-07 17:30:46
在使用FCKeditor 2.0時遇到的2個問題
1、漢化問題
FCKeditor 2.0是不支持中文的,不過查看了一下自帶的幫助文件,發現可以自定義語言版本,方法如下
(1)編輯edit/lang/fcklanguagemanager.js
將下面語句
FCKLanguageManager.AvailableLanguages = 
{
'ar' : 'Arabic',
'bs' : 'Bosnian',
'ca' : 'Catalan',
'en' : 'English',
'es' : 'Spanish',
'et' : 'Estonian',
'fi' : 'Finnish',
'fr' : 'French',
'gr' : 'Greek',
'he' : 'Hebrew',
'hr' : 'Croatian',
'it' : 'Italian',
'ko' : 'Korean',
'lt' : 'Lithuanian',
'no' : 'Norwegian',
'pl' : 'Polish',
'sr' : 'Serbian (Cyrillic)',
'sr-latn' : 'Serbian (Latin)',
'sv' : 'Swedish'
}
添加一行 'zh-cn'    : 'Chinese' 從而變成
FCKLanguageManager.AvailableLanguages = 
{
'ar' : 'Arabic',
'bs' : 'Bosnian',
'ca' : 'Catalan',
'en' : 'English',
'es' : 'Spanish',
'et' : 'Estonian',
'fi' : 'Finnish',
'fr' : 'French',
'gr' : 'Greek',
'he' : 'Hebrew',
'hr' : 'Croatian',
'it' : 'Italian',
'ko' : 'Korean',
'lt' : 'Lithuanian',
'no' : 'Norwegian',
'pl' : 'Polish',
'sr' : 'Serbian (Cyrillic)',
'sr-latn' : 'Serbian (Latin)',
'sv' : 'Swedish',
'zh-cn'     : 'Chinese'
}
然后在參照editor/lang/en.js進行翻譯,把翻譯的結果以UTF-8編碼保存為zh-cn.js的文件保存在

editor/lang目錄下就可以了。那么再調用FCKeditor時,就會自動進行加載zh-cn.js完成漢化。但是我按

照這個步驟完成后在調用FCKeditor時會出現錯誤,不知道問題出在哪里。我已經把自己漢化好的zh-cn.js

上傳到我的網站上: http://www.shaof.com/download/zh-cn.js 大家如果有興趣可以下載下來試試,看

看能否成功。

2、圖片文件上傳路徑問題
安裝我文章里面的設置,上傳路徑設置為UserFiles/,但是上傳圖片文件時,FCKeditor都自動把文件上傳到UserFiles/image目錄下面,自做主張的建立了一個image目錄,很是不爽。原因不明。

希望對FCKeditor感興趣的朋友一起來解決這兩個問題。

 Tung 回復于:2004-12-07 22:39:06
不支持中文?那怎么應用?觀望中。。。

 tjyihui 回復于:2004-12-08 07:11:59
to Tung
不是不支持中文輸入和顯示,而是FCKeditor的界面不能實現漢化,見我上傳的圖2中,如upload,應該顯示為“上傳”的。

 xmlv 回復于:2004-12-08 08:43:40
樓主在天津?有空拜訪拜訪

 Tung 回復于:2004-12-08 08:46:39
[quote:f7de2f5ba1="tjyihui"]to Tung
不是不支持中文輸入和顯示,而是FCKeditor的界面不能實現漢化,見我上傳的圖2中,如upload,應該顯示為“上傳”的。[/quote:f7de2f5ba1]

呵呵,不好意思,理解錯誤。

界面漢化可以更好推廣,Try。

 muyan 回復于:2004-12-08 09:42:14
2、修改配置文件FCKeditor\editor\filemanager\browser\default\connectors\php\connector.php 
// Get the "UserFiles" path. 
$GLOBALS["UserFilesPath"] = '/UserFiles/' ; 
UserFiles為文件上傳的路徑,與本文開頭所給的例子相對應,大家可以自行修改。 

第二步不需要

// Get the "UserFiles" path.
$GLOBALS["UserFilesPath"] = '' ;

if ( isset( $_GET['ServerPath'] ) )
{
$GLOBALS["UserFilesPath"] = $_GET['ServerPath'] ;
if ( ! ereg( '/$', $GLOBALS["UserFilesPath"] ) )
$GLOBALS["UserFilesPath"] .= '/' ;
}
else
$GLOBALS["UserFilesPath"] = '/UserFiles/' ;

// Map the "UserFiles" path to a local directory.
$GLOBALS["UserFilesDirectory"] = GetRootPath() . str_replace( '/', '\\', $GLOBALS["UserFilesPath"] ) ;

源文件中有判斷,應該更改$GLOBALS["UserFilesPath"] = '/UserFiles/' ;默認路徑

 fans1 回復于:2004-12-08 15:55:45
/*
 * FCKeditor - The text editor for internet
 * Copyright (C) 2003-2004 Frederico Caldeira Knabben
 * 
 * Licensed under the terms of the GNU Lesser General Public License:
 *  http://www.opensource.org/licenses/lgpl-license.php
 * 
 * For further information visit:
 *  http://www.fckeditor.net/
 * 
 * File Name: en.js
 *  English language file.
 * 
 * Version:  2.0 RC1
 * Modified: 2004-11-26 01:58:51
 * 
 * File Authors:
 *  Frederico Caldeira Knabben (fredck@fckeditor.net)
 */

var FCKLang =
{
// Language direction : "ltr" (left to right) or "rtl" (right to left).
Dir : "ltr",

ToolbarCollapse : "Collapse Toolbar",
ToolbarExpand : "Expand Toolbar",

// Toolbar Items and Context Menu
Save : "保存",
NewPage : "新建頁面",
Preview : "預覽",
Cut : "剪切",
Copy : "拷貝",
Paste : "粘貼",
PasteText : "純文本粘貼",
PasteWord : "來自Word的粘貼",
Print : "打印",
SelectAll : "選擇全部",
RemoveFormat : "去除格式",
InsertLinkLbl : "鏈接",
InsertLink : "插入/編輯 鏈接",
RemoveLink : "去除鏈接",
InsertImageLbl : "圖片",
InsertImage : "插入/編輯 圖片",
InsertTableLbl : "表格",
InsertTable : "插入/編輯 表格",
InsertLineLbl : "水平線",
InsertLine : "插入水平線",
InsertSpecialCharLbl: "特殊字符",
InsertSpecialChar : "插入特殊字符",
InsertSmileyLbl : "表情符號",
InsertSmiley : "插入表情符號",
About : "關于FCKeditor",
Bold : "粗體",
Italic : "斜體",
Underline : "下劃線",
StrikeThrough : "文字刪除線",
Subscript : "下標",
Superscript : "上標",
LeftJustify : "左對齊",
CenterJustify : "居中對齊",
RightJustify : "右對齊",
BlockJustify : "兩端對齊",
DecreaseIndent : "減少縮進",
IncreaseIndent : "增加縮進",
Undo : "撤銷",
Redo : "還原",
NumberedListLbl : "自動編號",
NumberedList : "插入/刪除 自動編號",
BulletedListLbl : "項目符號",
BulletedList : "插入/刪除 項目符號",
ShowTableBorders : "顯示表格線",
ShowDetails : "顯示明細",
Style : "樣式",
FontFormat : "格式",
Font : "字體",
FontSize : "字體大小",
TextColor : "字體顏色",
BGColor : "背景色",
Source : "Html格式",
Find : "查找",
Replace : "替換",

// Context Menu
EditLink : "編輯鏈接",
InsertRow : "插入行",
DeleteRows : "刪除行",
InsertColumn : "插入列",
DeleteColumns : "刪除列",
InsertCell : "插入單元格",
DeleteCells : "刪除單元格",
MergeCells : "合并單元格",
SplitCell : "拆分單元格",
CellProperties : "單元格屬性",
TableProperties : "表格屬性",
ImageProperties : "圖片屬性",

FontFormats : "Normal;Formatted;Address;Heading 1;Heading 2;Heading 3;Heading 4;Heading 5;Heading 6",

// Alerts and Messages
ProcessingXHTML : "正在處理XHTML. 請稍等...",
Done : "完成",
PasteWordConfirm : "粘貼的內容來自Word. 你需要去除它的格式嗎?",
NotCompatiblePaste : "這個操作需要Internet Explorer version 5.5 或以上版本. 你需要粘貼它而不去除格式嗎",
UnknownToolbarItem : "未知的工具欄項目 \"%1\"",
UnknownCommand : "未知的命令名 \"%1\"",
NotImplemented : "命令無法執行",
UnknownToolbarSet : "工具欄設置 \"%1\" 不存在",

// Dialogs
DlgBtnOK : "確定",
DlgBtnCancel : "取消",
DlgBtnClose : "關閉",
DlgAdvancedTag : "高級",

// General Dialogs Labels
DlgGenNotSet : "&not set&",
DlgGenId : "Id",
DlgGenLangDir : "Language Direction",
DlgGenLangDirLtr : "Left to Right (LTR)",
DlgGenLangDirRtl : "Right to Left (RTL)",
DlgGenLangCode : "Language Code",
DlgGenAclearcase/" target="_blank" >ccessKey : "Access Key",
DlgGenName : "Name",
DlgGenTabIndex : "Tab Index",
DlgGenLongDescr : "Long Description URL",
DlgGenClass : "Stylesheet Classes",
DlgGenTitle : "Advisory Title",
DlgGenContType : "Advisory Content Type",
DlgGenLinkCharset : "Linked Resource Charset",
DlgGenStyle : "Style",

// Image Dialog
DlgImgTitle : "圖片屬性",
DlgImgInfoTab : "圖片內容",
DlgImgBtnUpload : "放送到服務器",
DlgImgURL : "地址",
DlgImgUpload : "上傳",
DlgImgBtnBrowse : "瀏覽服務器",
DlgImgAlt : "替換的文本",
DlgImgWidth : "寬度",
DlgImgHeight : "高度",
DlgImgLockRatio : "鎖定比例",
DlgBtnResetSize : "重置尺寸",
DlgImgBorder : "邊框",
DlgImgHSpace : "橫向坐標",
DlgImgVSpace : "縱向坐標",
DlgImgAlign : "對齊方式",
DlgImgAlignLeft : "左邊",
DlgImgAlignAbsBottom: "絕對靠底",
DlgImgAlignAbsMiddle: "絕對靠中",
DlgImgAlignBaseline : "基準線",
DlgImgAlignBottom : "靠底",
DlgImgAlignMiddle : "靠中",
DlgImgAlignRight : "靠右",
DlgImgAlignTextTop : "文字頂",
DlgImgAlignTop : "頂端",
DlgImgPreview : "預覽",
DlgImgMsgWrongExt : "對不起, 只運行上傳以下類型的文件:\n\n" + FCKConfig.ImageUploadAllowedExtensions + "\n\n操作取消.",
DlgImgAlertSelect : "請選擇要上傳的文件.",
DlgImgAlertUrl : "Please type the image URL",

// Link Dialog
DlgLnkWindowTitle : "鏈接",
DlgLnkInfoTab : "鏈接內容",
DlgLnkTargetTab : "目標",

DlgLnkType : "鏈接類型",
DlgLnkTypeURL : "地址",
DlgLnkTypeAnchor : "書簽",
DlgLnkTypeEMail : "E-Mail",
DlgLnkProto : "Protocol",
DlgLnkProtoOther : "&other&",
DlgLnkURL : "URL",
DlgLnkBtnBrowse : "瀏覽服務器",
DlgLnkAnchorSel : "Select an Anchor",
DlgLnkAnchorByName : "By Anchor Name",
DlgLnkAnchorById : "By Element Id",
DlgLnkNoAnchors : "&No anchors available in the document&",
DlgLnkEMail : "E-Mail Address",
DlgLnkEMailSubject : "Message Subject",
DlgLnkEMailBody : "Message Body",
DlgLnkUpload : "上傳",
DlgLnkBtnUpload : "發送到服務器",

DlgLnkTarget : "目標",
DlgLnkTargetFrame : "&frame&",
DlgLnkTargetPopup : "&popup window&",
DlgLnkTargetBlank : "新建窗口 (_blank)",
DlgLnkTargetParent : "父框架 (_parent)",
DlgLnkTargetSelf : "相同框架 (_self)",
DlgLnkTargetTop : "整頁 (_top)",
DlgLnkTargetFrame : "Target Frame Name",
DlgLnkPopWinName : "Popup Window Name",
DlgLnkPopWinFeat : "Popup Window Features",
DlgLnkPopResize : "Resizable",
DlgLnkPopLocation : "Location Bar",
DlgLnkPopMenu : "Menu Bar",
DlgLnkPopScroll : "Scroll Bars",
DlgLnkPopStatus : "Status Bar",
DlgLnkPopToolbar : "Toolbar",
DlgLnkPopFullScrn : "全屏 (IE)",
DlgLnkPopDependent : "Dependent (Netscape)",
DlgLnkPopWidth : "寬度",
DlgLnkPopHeight : "高度",
DlgLnkPopLeft : "Left Position",
DlgLnkPopTop : "Top Position",

DlgLnkMsgWrongExtA : "對不起, 只運行上傳以下類型的文件:\n\n" + FCKConfig.LinkUploadAllowedExtensions + "\n\n操作取消.",
DlgLnkMsgWrongExtD : "對不起, 以下類型的文件不運行上傳:\n\n" + FCKConfig.LinkUploadAllowedExtensions + "\n\n操作取消.",

DlnLnkMsgNoUrl : "Please type the link URL",
DlnLnkMsgNoEMail : "Please type the e-mail address",
DlnLnkMsgNoAnchor : "Please select an anchor",

// Color Dialog
DlgColorTitle : "顏色選擇",
DlgColorBtnClear : "清除",
DlgColorHighlight : "高亮",
DlgColorSelected : "已選擇",

// Smiley Dialog
DlgSmileyTitle : "插入一個表情符號",

// Special Character Dialog
DlgSpecialCharTitle : "選擇特殊字符",

// Table Dialog
DlgTableTitle : "表格屬性",
DlgTableRows : "行數",
DlgTableColumns : "列數",
DlgTableBorder : "邊框大小",
DlgTableAlign : "對齊方式",
DlgTableAlignNotSet : "<無>",
DlgTableAlignLeft : "居左",
DlgTableAlignCenter : "居中",
DlgTableAlignRight : "居右",
DlgTableWidth : "寬度",
DlgTableWidthPx : "像素",
DlgTableWidthPc : "百分比",
DlgTableHeight : "高度",
DlgTableCellSpace : "單元格間距",
DlgTableCellPad : "單元格填充",
DlgTableCaption : "標題",

// Table Cell Dialog
DlgCellTitle : "單元格屬性",
DlgCellWidth : "寬度",
DlgCellWidthPx : "像素",
DlgCellWidthPc : "百分比",
DlgCellHeight : "高度",
DlgCellWordWrap : "自動折行",
DlgCellWordWrapNotSet : "<無>",
DlgCellWordWrapYes : "是",
DlgCellWordWrapNo : "否",
DlgCellHorAlign : "水平對齊方式",
DlgCellHorAlignNotSet : "<無>",
DlgCellHorAlignLeft : "居左",
DlgCellHorAlignCenter : "居中",
DlgCellHorAlignRight: "居右",
DlgCellVerAlign : "垂直對齊方式",
DlgCellVerAlignNotSet : "<無>",
DlgCellVerAlignTop : "頂端",
DlgCellVerAlignMiddle : "居中",
DlgCellVerAlignBottom : "底端",
DlgCellVerAlignBaseline : "基準線",
DlgCellRowSpan : "行跨越",
DlgCellCollSpan : "列跨越",
DlgCellBackColor : "背景色",
DlgCellBorderColor : "單元線顏色",
DlgCellBtnSelect : "選擇...",

// Find Dialog
DlgFindTitle : "查找",
DlgFindFindBtn : "查找",
DlgFindNotFoundMsg : "指定字符無法找到.",

// Replace Dialog
DlgReplaceTitle : "替換",
DlgReplaceFindLbl : "替換內容:",
DlgReplaceReplaceLbl : "替換為:",
DlgReplaceCaseChk : "區分大小寫",
DlgReplaceReplaceBtn : "替換",
DlgReplaceReplAllBtn : "全部替換",
DlgReplaceWordChk : "完全匹配",

// Paste Operations / Dialog
PasteErrorPaste : "你的瀏覽器安全設置不允許編輯器自動執行粘貼操作。請使用快捷鍵(Ctrl+V)手工執行.",
PasteErrorCut : "你的瀏覽器安全設置不允許編輯器自動執行剪切操作。請使用快捷鍵(Ctrl+X)手工執行.",
PasteErrorCopy : "你的瀏覽器安全設置不允許編輯器自動執行拷貝操作。請使用快捷鍵(Ctrl+C)手工執行.",

PasteAsText : "純文本粘貼",
PasteFromWord : "來自Word的粘貼",

DlgPasteMsg : "The editor was not able to automaticaly execute pasting because of the <STRONG>security settings</STRONG> of your browser.<BR>Please paste inside the following box using the keyboard (<STRONG>Ctrl+V</STRONG>) and hit <STRONG>OK</STRONG>.",

// Color Picker
ColorAutomatic : "自動",
ColorMoreColors : "更多顏色...",

// About Dialog
DlgAboutVersion : "版本",
DlgAboutLicense : "Licensed under the terms of the GNU Lesser General Public License",
DlgAboutInfo : "查看更多信息請到"
}

 fans1 回復于:2004-12-08 15:58:16
其實用firefox的java控制臺幾下就能調好了,就是一些小問題而已

 tjyihui 回復于:2004-12-09 08:48:48
第一個漢化的問題已經解決啦。原來是那個zh-cn.js不是UTF-8編碼格式,所以導致不能使用。 我已經更新了http://www.shaof.com/download/zh-cn.js 
大家可以去下載,然后安裝我上面說的方法就可以實現界面的漢化了。

 xmlv 回復于:2004-12-09 09:12:59
??我加上zh-cn:Chinese就報錯
js錯誤信息為:
行:21
字符:1
錯誤:'fcklanguagemanager'未定義

 minimu 回復于:2004-12-13 10:43:45
樓主幫忙

我安裝FCKeditor,安裝你上面所說的

總是提示fckeditor.html JavaScript錯誤
說23行缺少":"

 muyan 回復于:2004-12-17 14:09:04
這些都不是問題,關鍵是6.0下根本沒法用

 xmlv 回復于:2004-12-18 15:40:30
怎么讓工具條默認是折疊???

 xmlv 回復于:2004-12-18 16:39:55
get it.
$editor->Config = Array("ToolbarStartExpanded"=>"false");

 夜貓子 回復于:2004-12-18 17:05:35
在FCKEditor下你可以看到一個fckconfig.js文件,里邊有諸如
FCKConfig.CustomConfigurationsPath
FCKConfig.EditorAreaCSS
這樣一些東西
通過$FCKEditor->Config,就可以改變這些設置
比如xmlv說的那樣

 水若寒 回復于:2004-12-19 20:02:22
Linux作服務器,安裝FCK2.0,IE6無法正常顯示,FIREFOX可以....

 cagecn 回復于:2004-12-20 20:34:10
我改了
$GLOBALS["UserFilesPath"] = '/UserFiles/' ;
但還是錯的
還需要改什么
UserFiles在什么地方

mozilla下有這個錯誤
錯誤: this.DOMDocument has no properties
源文件:http://127.0.0.1/FCKeditor/editor/filemanager/browser/default/js/fckxml.js
行:102

ie6(xp sp2)下
frmresourceslist.html文件119行2列錯誤
提示缺少對象


請求解答,謝謝

 sobo 回復于:2004-12-20 22:21:23
請問樓主,怎么在編輯器中預置一段文字呢?

比如:
<?php

                $value="test";
//引入在線編輯器
include("./FCKeditor/fckeditor.php") ;
$oFCKeditor = new FCKeditor('FCKeditor1') ;
$oFCKeditor->BasePath = '../FCKeditor/' ;
$oFCKeditor->ToolbarSet = 'Default' ;
$oFCKeditor->InstanceName = 'EditorDefault' ;
$oFCKeditor->Width = '100%' ;
$oFCKeditor->Height = '400' ;
$oFcKeditor->value = $value ;
$oFCKeditor->Create() ;
?>

好像不行,這里應該怎么用呢?

 tjyihui 回復于:2004-12-21 22:27:51
to sobo 
對于你的疑問建議你看一下FCKeditor自帶的范例程序。
下面是我寫的一段代碼
<?php
//引入在線編輯器
include("../FCKeditor/fckeditor.php") ;

$ArticleContent="test";
$oFCKeditor = new FCKeditor('FCKeditor1')  ;
$oFCKeditor->BasePath = '../FCKeditor/' ;
$oFCKeditor->ToolbarSet = 'Shaof' ;
$oFCKeditor->Value = $ArticleContent ;
$oFCKeditor->InstanceName = 'EditorDefault' ;
$oFCKeditor->Width = '100%' ;
$oFCKeditor->Height = '400' ;
$oFCKeditor->Create() ;
?>

應該是沒問題的

 xmlv 回復于:2004-12-22 11:29:50
明顯的路徑錯誤啊

 cagecn 回復于:2004-12-22 18:24:06
rc2出來了

我的問題已解決,有人需要我可以把rc1的文件給他,初步斷定是文件的編碼不對

 zhaochao 回復于:2005-01-08 00:52:47
我是 新人 大家照顧照顧

 StartNow 回復于:2005-01-17 15:32:54
用了rc 2  發現了一些問題, 在有的機子上是正常的, 有的機子上會提示 js錯誤 無法正常顯示.  firefox 下面除了中文部分顯示亂碼外 其他正常。

一些朋友也同樣有這個問題:
http://community.csdn.net/Expert/topic/3639/3639328.xml?temp=.6439783

不解!!!

 mjy1225 回復于:2005-05-14 02:29:14
上傳文件那,少了個刪除功能,我想添加上去,不知道要修改那一個文件??

 hightman 回復于:2005-05-16 01:01:23
不覺得FCKeditor實在是太慢了嗎?

我曾經花了不少時間整合修改, 結果被用戶狂罵太慢,而且不支持IE5.0(很多人用win98沒升級).... :(

 mayichao 回復于:2005-06-10 17:53:29
兄弟們,有誰解決過這種問題的,幫個忙吧。
在IE中總是說缺少“:”。

 HonestQiao 回復于:2005-06-10 22:36:46
我用過,每什么問題的

 zyzhao 回復于:2005-06-24 13:42:33
請問一下在IE6.0.2800.1106下無法使用,老提示缺少“:”;
請問這個問題怎么解決。

謝謝。

 smaplet 回復于:2005-07-13 09:57:52
不好意思問個初級的問題,就是編輯后的內容,我想把他存入數據庫,難道要將生成的html代碼都存入到db里嗎?

 sickcat2004 回復于:2005-07-20 02:16:28
在php程序里如何獲得上傳圖片的路徑,名字,希望讓圖片的名字得到處理后再
上傳,是不是得改fck的源代碼?

 nbxmedia 回復于:2005-07-20 10:31:55
FCK好是好,但是只支持UTF8,如果你的網站是GB編碼的,那最好還是Htmlarea+ImageManager

 HonestQiao 回復于:2005-07-20 11:54:10
advanceeditor\editor\filemanager\browser\default\connectors\php

看這里的文件

原文轉自:http://www.anti-gravitydesign.com

国产97人人超碰caoprom_尤物国产在线一区手机播放_精品国产一区二区三_色天使久久综合给合久久97