青海網站建設、網絡推廣最好的公司--您身邊的網站建設專家,馬上拿起電話,聯系我們:0971-8235355   
青海西寧網站建設、網站制作公司-西寧威勢電子信息服務有限公司 首頁 |  公司簡介 |  網站建設 |  網絡推廣 |  空間租用 |  域名注冊 |  企業郵局 |  網絡安全 |  網站編程 |  客服中心 |  聯系我們 |  人才招聘
 
西寧威勢最新網站制做案例展示
Lastest Project
 
西寧網站建設  
當前位置為:首頁 >> .NET編程 >> 正文  
[原創]修改 Fckeditor ,使之保存文件時自動按時間創建目錄,并修復鏈接上傳失效的BUG

文章來源: 西寧威勢電子信息服務有限公司     發布時間:2011-7-27    瀏覽次數:6417   

在找到fckconfig.js文件的299號左右,將代碼修改成下面的,可以修復添加鏈接時無法上傳附件的BUG

FCKConfig.LinkUpload = true ;
FCKConfig.LinkUploadURL = FCKConfig.BasePath + 'filemanager/connectors/' + _QuickUploadLanguage + '/upload.' + _QuickUploadExtension + '?Type=File';

 

將CONFIG.ASCX的代碼做如下修改

        HtmlExtensions = new string[] { "html", "htm", "xml", "xsd", "txt", "js" };

        TypeConfig["File"].AllowedExtensions = new string[] { "7z", "aiff", "asf", "avi", "bmp", "csv", "doc", "fla", "flv", "gif", "gz", "gzip", "jpeg", "jpg", "mid", "mov", "mp3", "mp4", "mpc", "mpeg", "mpg", "ods", "odt", "pdf", "png", "ppt", "pxd", "qt", "ram", "rar", "rm", "rmi", "rmvb", "rtf", "sdc", "sitd", "swf", "sxc", "sxw", "tar", "tgz", "tif", "tiff", "txt", "vsd", "wav", "wma", "wmv", "xls", "xml", "zip" };
        TypeConfig["File"].DeniedExtensions = new string[] { };
        TypeConfig["File"].FilesPath = "%UserFilesPath%";
        TypeConfig["File"].FilesAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");
        TypeConfig["File"].QuickUploadPath = "%UserFilesPath%" + DateTime.Now.Year.ToString() + "/" + DateTime.Now.Month.ToString() + "/";
        TypeConfig["File"].QuickUploadAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");

        TypeConfig["Image"].AllowedExtensions = new string[] { "bmp", "gif", "jpeg", "jpg", "png" };
        TypeConfig["Image"].DeniedExtensions = new string[] { };
        TypeConfig["Image"].FilesPath = "%UserFilesPath%";
        TypeConfig["Image"].FilesAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%" + DateTime.Now.Year.ToString() + "/" + DateTime.Now.Month.ToString() + "/");
        TypeConfig["Image"].QuickUploadPath = "%UserFilesPath%" + DateTime.Now.Year.ToString() + "/" + DateTime.Now.Month.ToString() + "/";
        TypeConfig["Image"].QuickUploadAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");

        TypeConfig["Flash"].AllowedExtensions = new string[] { "swf", "flv" };
        TypeConfig["Flash"].DeniedExtensions = new string[] { };
        TypeConfig["Flash"].FilesPath = "%UserFilesPath%";
        TypeConfig["Flash"].FilesAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");
        TypeConfig["Flash"].QuickUploadPath = "%UserFilesPath%" + DateTime.Now.Year.ToString() + "/" + DateTime.Now.Month.ToString() + "/";
        TypeConfig["Flash"].QuickUploadAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");

        TypeConfig["Media"].AllowedExtensions = new string[] { "aiff", "asf", "avi", "bmp", "fla", "flv", "gif", "jpeg", "jpg", "mid", "mov", "mp3", "mp4", "mpc", "mpeg", "mpg", "png", "qt", "ram", "rm", "rmi", "rmvb", "swf", "tif", "tiff", "wav", "wma", "wmv" };
        TypeConfig["Media"].DeniedExtensions = new string[] { };
        TypeConfig["Media"].FilesPath = "%UserFilesPath%";
        TypeConfig["Media"].FilesAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");
        TypeConfig["Media"].QuickUploadPath = "%UserFilesPath%";
        TypeConfig["Media"].QuickUploadAbsolutePath = (UserFilesAbsolutePath == "" ? "" : "%UserFilesAbsolutePath%");

 

即可在上傳文件時,將文件按時間目錄名自動歸檔保存到服務器上。


上一篇:[原創]ACCESS 查詢時使用 LIKE語句
下一篇:沒有下一篇
評論列表
正在加載評論……
  
評論   
呢  稱:
驗證碼: 若看不清請點擊更換!
內  容:
 
 
  在線洽談咨詢:
點擊這里,在線洽談   點擊這里,在線洽談   點擊這里,在線洽談
與我交談  與我交談 與我交談
乘車路線    匯款方式   加盟合作  人才招聘  
公司地址:青海省西寧市西關大街73號(三二四部隊招行所四樓)     青ICP備13000578號-1 公安機關備案號:63010402000123    
QQ:147399120    mail:[email protected]    電話: 13897410341    郵編:810000
© Copyright( 2008-2009) QhWins.Com All Rights Reserved    版權所有:西寧威勢電子信息服務有限公司 未經書面制授權,請勿隨意轉載!
業務:青海網站制做青海網站建設青海網頁設計西寧網站制做西寧網站建設青海域名注冊青海網絡推廣青海網站推廣青海空間租用青海軟件開發網站安全網絡安全

香港六合彩开奖结果网