WP电子商务:修改发售时发送给管理员的交易报告电子邮件

问题描述:

I am looking to modify the transaction results email that is sent to the admin upon sale of an item (include and exclude certain information, etc), I've researched on google and looked on the wp-ecommerce support site and have been unable to locate where this is being done currently (a lot of references to older versions of the plugin that have since changed significantly). I will continue to look for where to do this but as I am not well versed in wp-ecommerce (or wordpress for that matter) I am not entirely sure where to look.

If anyone could shed light on this, it would be greatly appreciated.

我希望修改在销售商品时发送给管理员的交易结果电子邮件(包含和排除) 某些信息等),我在google上进行了研究并查看了wp-ecommerce支持网站,并且无法找到当前正在进行此处的工作(很多时候对插件的旧版本的引用都发生了很大变化) 。 我将继续寻找在哪里这样做,但由于我不熟悉wp-ecommerce(或wordpress),我不完全确定在哪里看。 p>

如果有人 能够说明这一点,我们将不胜感激。 p> div>

Under wp-e-commerce/wpsc-updates/updating_tasks.php

Line 356-372 is where the email section is.

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'));
    }
}

If you want to go even deeper into the whole email code, you can also go into this section

wp-e-commerce/wpsc-includes/purchase-log-notification.class.php

I created a plugin for this and many other wp e-commerce features. With the shop styling plugin you can modify the transaction report with placeholders as well as any other mails from the wordpress backend without modifying any plugin files.