1

我正在寻找修改在出售商品时发送给管理员的交易结果电子邮件(包括和排除某些信息等),我在谷歌上进行了研究并查看了 wp-ecommerce 支持网站,但无法找到当前正在执行此操作的位置(许多对旧版本插件的引用,这些版本已经发生了重大变化)。我将继续寻找在哪里执行此操作,但由于我不精通 wp-ecommerce(或 wordpress),我不完全确定在哪里寻找。

如果有人能阐明这一点,将不胜感激。

4

2 回答 2

3

在 wp-e-commerce/wpsc-updates/updating_tasks.php 下

第 356-372 行是电子邮件部分所在的位置。

add_option('wpsc_email_receipt', '', __('Thank you for purchasing with %shop_name%, any items to be shipped will be processed as soon as possible, any items that can be downloaded can be downloaded using the links on this page.All prices include tax and postage and packaging where applicable.You ordered these items:%product_list%%total_shipping%%total_price%', 'wpsc'), 'yes');
add_option('wpsc_email_admin', '', __('%product_list%%total_shipping%%total_price%', 'wpsc'), 'yes');

if(get_option('wpsc_email_receipt') == '') {
    if(get_option('email_receipt') != '') {
        update_option('wpsc_email_receipt', get_option('email_receipt'));
    } else {
        update_option('wpsc_email_receipt', __('Thank you for purchasing with %shop_name%, any items to be shipped will be processed as soon as possible, any items that can be downloaded can be downloaded using the links on this page.All prices include tax and postage and packaging where applicable.You ordered these items:%product_list%%total_shipping%%total_price%', 'wpsc'));
    }
}
if(get_option('wpsc_email_admin') == '') {
  if(get_option('email_admin') != '') {
        update_option('wpsc_email_admin', get_option('email_admin'));
    } else {
        update_option('wpsc_email_admin', __('%product_list%%total_shipping%%total_price%', 'wpsc'));
    }
}

如果您想更深入地了解整个电子邮件代码,也可以进入此部分

wp-电子商务/wpsc-includes/purchase-log-notification.class.php

于 2013-03-17T05:27:55.907 回答
1

我为此和许多其他 wp 电子商务功能创建了一个插件。使用商店样式插件,您可以使用占位符修改交易报告以及来自 wordpress 后端的任何其他邮件,而无需修改任何插件文件。

于 2013-04-01T06:06:09.400 回答