给ECSHOP后台商品简单描述为富文本编辑器
发布时间:2019-12-16 11:17:02作者:admin点击:190
修改方法
首先来修改 /admin/includes/lib_main.php 文件将
function create_html_editor($input_name, $input_value = '')
修改为
function create_html_editor($input_name, $input_value = '',$fckid=0)
继续向下找到
$smarty->assign('FCKeditor', $FCKeditor);
将它修改为
if ($fckid)
{
$smarty->assign('FCKeditor'.$fckid, $FCKeditor);
}
else
{
$smarty->assign('FCKeditor', $FCKeditor);
}
接下来要修改 /admin/goods.php 文件找到
create_html_editor('goods_desc', $goods['goods_desc']);
在它下面另添加一行
create_html_editor('goods_brief', $goods['goods_brief'],2);
最后修改一下对应的模板文件 /admin/templates/goods_info.htm,找到下面这行代码
并且修改为
{$FCKeditor2}
自后,为了能够顺利的保存较长内容,还应该修改一下 ecs_goods 表的 goods_brief 字段,将它的字段类型从 varchar(255) 修改为 text 至于如何修改,有很多途径。
- 上一篇 : 如何在Drupal实现Click insert textar
- 下一篇 : PHPCMS二次开 自定义标签教程