I am having a nightmare trying to extend the admin emails in wp ecommerce for wordpress.
The reports are very basic and no documentation to support adding to the emails.
I want to be able to add shipping address details to the admin report so I don’t have to log into the WordPress backend to view the purchase_log everytime I make a sale.
I have tried following an example from here http://getshopped.org/forums/topic/add-shipping-method-to-admin-email/ but with no luck.
I have added this:
$report = str_replace( '%shipping_country%', $purchase_log['shipping_country'], $report );
$report = str_replace( '%billing_country%', $purchase_log['billing_country'], $report );
$report = str_replace( '%shipping_country%', $purchase_log['shipping_country'], $report );
$report = str_replace( '%buyer_name%', wpsc_display_purchlog_buyers_name(), $report );
$report = str_replace( '%shipping_address%', wpsc_display_purchlog_shipping_address(), $report );
$report = str_replace( '%shipping_city%', wpsc_display_purchlog_shipping_city(), $report );
$report = str_replace( '%shipping_country%', wpsc_display_purchlog_shipping_country(), $report );
to this (which is originally in wpsc_transaction_results_functions.php)
$report = apply_filters( 'wpsc_transaction_result_report', $report );
$report = str_replace( '%purchase_id%', $report_id, $report );
$report = str_replace( '%product_list%', $report_product_list, $report );
$report = str_replace( '%total_tax%', $total_tax, $report );
$report = str_replace( '%total_shipping%', $total_shipping_email, $report );
etc…
but I get the following error after entering credit card details – does anyone know of a simple way to add to the report?
Cheers guys

I know it’s been a while since this was opened, but I found a solution to this. It’s a bit messy, but it works.
So just above the filters in the above code within
wpsc-transaction_results_functions.phpabove I created a database query that looked like this:I then found out what parts of the array results was the information I needed, I did this by adding:
I then put through an order and the array appeared on the transaction results screen. So I then set the variables…
I then created the shortcodes i.e.
And don’t forget to remove the
print_r ($cust_info);etc.