Configure FCKeditor to upload images

Source: Internet
Author: User

1. Modify $ config ['enabled'] = true in editor \ filemanager \ upload \ PHP \ editor \ filemanager \ browser \ Default \ connectors \ PHP \ config. php;

2. Modify $ config ['enabled'] = true in editor \ filemanager \ upload \ PHP \ config. php;

3. Modify the getrootpath function in util. php under editor \ filemanager \ upload \ PHP.CopyCodeThe Code is as follows:

Function getrootpath () {$ srealpath = realpath ('. '); $ srealpath = str_replace (' \ ','/', $ srealpath); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); return $ srealpath. '/';}

The getrootpath function in Io. php under editor \ filemanager \ browser \ Default \ connectors \ PHP is also available.Copy codeThe Code is as follows:

Function getrootpath () {$ srealpath = realpath ('. '); $ srealpath = str_replace (' \ ','/', $ srealpath); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath ,'/')); $ srealpath = substr ($ srealpath, 0, strrpos ($ srealpath, '/'); return $ srealpath. '/';}

Then modify the config in editor \ filemanager \ browser \ Default \ connectors \ PHP. the $ config ['userfilespath'] variable of the PHP file and the config under editor \ filemanager \ upload \ PHP. the $ config ['userfilespath'] variable in PHP is enough. However, the image cannot be seen in the editor, but there is no problem when it is displayed as content.

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.