轻源码

  • QingYuanMa.com
  • 全球最大的互联网技术和资源下载平台
搜索
一起源码网 门户 ECShop网店 查看主题

ecshop编辑器FCKeditor修改成KindEditor编辑批量上传图片

发布者: heiya | 发布时间: 2018-11-24 12:36| 查看数: 3670| 评论数: 1|帖子模式

一直使用的编辑器是fck,这个不用多说,相信很多朋友用的很悲剧吧,特别是图片不能批量上传图片。
    今天小编就分享一下怎么换掉fck,放上实用的kindeditor,最新ecshop版本的哦。方法如下:
1、官方网站下载最新版kindeditor
现在最先版本的是:kindeditor4.1.4,官方网址:
2、上传解压
上传下载的压缩文件到你的网站include目录下,解压kindeditor4.1.4,将其文件夹名称改为:kindeditor

3、修改php文件
(1)打开admin/includes/lib_main.php,查找 create_html_editor
将以下内容:
function create_html_editor($input_name, $input_value = '')
{
    global $smarty;

    $editor = new FCKeditor($input_name);
    $editor->BasePath   = '../includes/fckeditor/';
    $editor->ToolbarSet = 'Normal';
    $editor->Width      = '100%';
    $editor->Height     = '320';
    $editor->Value      = $input_value;
    $FCKeditor = $editor->CreateHtml();
    $smarty->assign('FCKeditor', $FCKeditor);
}
替换成:
function create_html_editor($input_name, $input_value = '')
{
    global $smarty;

    $kindeditor="
   
    $input_value

    ";
    $smarty->assign('FCKeditor', $kindeditor);
}
(2)修改kindeditor/php/
上传目录修改includes/kindeditor/php/upload_json.php如下:
//文件保存目录路径
$save_path = $php_path . '../../../images/upload/';
//文件保存目录URL
$save_url = $php_url . '../../../images/upload/';
浏览服务器路径修改includes/kindeditor/php/file_manager_json.php如下:
//根目录路径,可以指定绝对路径,比如 /var/www/attached/
$root_path = $php_path . '../../../images/upload/';
//根目录URL,可以指定绝对路径,比如
$root_url = $php_url . '../../../images/upload/';
4、最后一步2.7.3版本的ecshop中在admin/template/goods_info.htm中 将提交按钮



修改为



ok,大功告成,在ecshop最新版本亲测正常使用。

最新评论

♡栀子花落♡ 发表于 2022-7-14 06:33
源码网站安装教程

轻源码让程序更轻更快

QingYuanMa.com

工作时间 周一至周六 8:00-17:30

侵权处理

客服QQ点击咨询

关注抖音号

定期抽VIP

Copyright © 2016-2021 https://www.171739.xyz/ 滇ICP备13200218号

快速回复 返回顶部 返回列表