專案採用 FCKeditor 作為富文本編輯器,整理部署步驟與常見問題解決方案。
FCKeditor 2.6.4.zip 與 FCKeditor.NET 控件組件FredCK.FCKeditorV2.dllweb.config 上傳路徑:
<add key="FCKeditor:UserFilesPath" value="/common/uploads" />
fckconfig.js 語言設定(必改,否則上傳報錯):
var _FileBrowserLanguage = 'aspx'; // 原為 'php'
var _QuickUploadLanguage = 'aspx'; // 原為 'php'
config.ascx 驗證開關(必改,否則提示 connector disabled):
private bool CheckAuthentication()
{
// 生產環境請實作真實驗證邏輯
// return (Session["IsAuthorized"] != null && (bool)Session["IsAuthorized"] == true);
return true; // 開發測試暫時開啟
}
完成以上設定即可正常使用。生產環境務必實作完整的 CheckAuthentication 防止未授權上傳。