When we want to use the kindeditor image upload function, there are two options: Local selection and image space selection, the default address of the image space is/kindeditor/attached/image/or lower on the server.
If you want to change the path, you need to find the/kindeditor/PHP/file_manager_json.php file, and then you can see the following lines:
// Specifies the absolute path of the root folder, for example,/var/www/attached/$ root_path = $ php_path. '.. /attached/'; // specifies the absolute path of the root folder, for example, http://www.yoursite.com/attached/?root_url = $ php_url. '.. /attached/'; // image extension $ ext_arr = array ('gif', 'jpg', 'jpeg ', 'png', 'bmp '); // folder name $ dir_name = empty ($ _ Get ['dir'])? '': Trim ($ _ Get ['dir']); If (! In_array ($ dir_name, array ('', 'image', 'flash', 'Media ', 'file') {echo" invalid directory name. "; exit;} if ($ dir_name! = '') {$ Root_path. = $ dir_name."/"; $ root_url. = $ dir_name."/"; if (! File_exists ($ root_path) {mkdir ($ root_path );}}
At the beginning of the year, I changed the addresses of $ root_path and $ root_url and found no effect. I printed $ dir_name using file_put_contents () and found that the default value is image. That is to say, after I changed the path to IMG, the path of the image space is the image below IMG. Therefore, I deleted several rows under the folder name and the modification was successful.