How to modify the fckeditor file Upload path

Source: Internet
Author: User

VS open the FCK project and open the file "FCKeditor. Net_2.6.3FileBrowserFileWorkerBase.cs"

Find this line

C # code
// Map the virtual path to the local server path.
String sServerDir = this. ServerMapFolder (resourceType, currentFolder, isQuickUpload );

// If you do not care about storing files by type, FCK divides the types into image, media, flash, and file
// Directly change it to this

String sServerDir = "d: somedir"; // note that this directory must grant the ASP.net read and write permissions.

After the modification is complete, recompile the entire project and copy the regenerated FredCK. FCKeditorV2.dll to your website.


You can upload and save the files in the following way, but there is a problem with the display because the path is incorrect:
Go to the file "fckeditoreditorfilemanagerconnectorsasp tutorial xconfig. ascx" and open it. Find the following snippet and follow the annotations I have noted.

C # code
// URL path to user files.
UserFilesPath = "/uploadfiles /";

// The connector tries to resolve the above UserFilesPath automatically.
// Use the following setting it you prefer to explicitely specify
// Absolute path. Examples: 'C: MySiteuserfiles 'or'/root/mysite/userfiles /'.
// Attention: The above 'userfilespath' URL must point to the same directory.
UserFilesAbsolutePath = "";

// Modify the above "UserFilesAbsolutePath" to your physical path,
// However, it may be a problem to access the uploaded files on the website.
// Note The last comment "Attention: the above 'userfilespath' URL must point to The same directory ."
// "UserFilesPath" and "UserFilesAbsolutePath" must point to the same folder,
// And UserFilesPath can only be a relative or virtual path

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.