全站插件24小时自动发货

实现ECSHOP客户下订单后给客户发邮件

ECSHOP目前是要管理者确认订单后,才会发邮件给客户。那么要怎么实现让ECSHOP下订单给客户发邮件,就先发邮件给客户,让他知道已经下订成功。需要的朋友可以参考方法下来实现:
首先打开flow.php文件中,找到如下代码:
    /* 给商家发邮件 */
    /* 增加是否给客服发送邮件选项 */
    if ($_CFG['send_service_email'] && $_CFG['service_email'] != '')
    {
        $tpl = get_mail_template('remind_of_new_order');
        $smarty->assign('order', $order);
        $smarty->assign('goods_list', $cart_goods);
        $smarty->assign('shop_name', $_CFG['shop_name']);
        $smarty->assign('send_date', date($_CFG['time_format']));
        $content = $smarty->fetch('str:' . $tpl['template_content']);
        send_mail($_CFG['shop_name'], $_CFG['service_email'], $tpl['template_subject'], $content, $tpl['is_html']);
    }
在以上的代码下面增加如下代码即可实现
    /* 增加是否给客户发送邮件选项 Add by ecshop.cx */
    if ($consignee['email'] != '')
    {
        $tpl = get_mail_template('order_confirm');
        $smarty->assign('order', $order);
        $smarty->assign('goods_list', $cart_goods);
        $smarty->assign('shop_name', $_CFG['shop_name']);
        $smarty->assign('send_date', date($_CFG['time_format']));
        $content = $smarty->fetch('str:' . $tpl['template_content']);
        send_mail($_CFG['shop_name'], $consignee['email'], $tpl['template_subject'], $content, $tpl['is_html']);
    } 

本文原创地址:https://www.ecshopok.com/article-370.html
版权所有 © 转载时必须以链接形式注明出处!

觉得本文对您有用,想收藏下来!方法很简单:请点击-〉
我们一直坚持白天工作、晚上熬夜更新资源,付出了巨大的精力和时间,其中的辛酸难以言述。

文章评论

暂无评论,来发表一个吧

发表 取消
充值有惊喜 ECSHOP插件网微信客服edait_cn