This is a discussion on Hack Offering: Put order number in email notification Subject: line within the osCMax v2 Customization/Mods forums, part of the osCMax v2.0 Forums category; The proprietor of my OSC -based store asked that the order number be included in the "Order Process" notification emails, ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| The proprietor of my OSC-based store asked that the order number be included in the "Order Process" notification emails, to assist in his organization and tracking. All I needed was a quick hack to catalog/checkout_process.php. I offer it here. The code is added starting around line 338. My comments are preceded with "BL": ( code code code ... ) if ($payment_class->email_footer) { $email_order .= $payment_class->email_footer . "\n\n"; } } // BL: Added this line $email_subject = EMAIL_TEXT_SUBJECT . " #" . $insert_id; // BL: Changed EMAIL_TEXT_SUBJECT to $email_subject tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], $email_subject, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); // send emails to other people // BL: Changed EMAIL_TEXT_SUBJECT to $email_subject if (SEND_EXTRA_ORDER_EMAILS_TO != '') { tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, $email_subject, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); } (code code code ...) Now instead of "Order Process" the subject line reads "Order Process #N" where N is the number of your new order. If you are using the PayPal IPN module, a similar hack must be applied since that module effectively replaces checkout_process. For IPN v1.3 it's in includes/modules/payment/paypal_ipn.php, the context is nearly identical except the order number is stored in $order_id. 2.2M2, again similar context, but the file is ext/modules/payment/paypal_ipn/ipn.php and the order number is in $_POST['invoice']. Can't say what the case is for other versions as I have not tried them. |
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| New Order Email Notification | winerack | osCMax v2 Installation issues | 3 | 03-22-2007 09:08 AM |
| order number in email subject | michael_s | New osCommerce Contributions | 0 | 02-16-2007 01:10 PM |
| Anyone implemented "order email only" hack? | xtech | osCommerce 2.2 Modification Help | 0 | 08-15-2004 06:38 PM |
| multiable copy of Email with different subject line | okatoma | osCommerce 2.2 Modification Help | 0 | 04-14-2004 07:58 PM |
| How to delete last line of order process email | Walter | osCommerce 2.2 Modification Help | 1 | 10-21-2003 07:30 PM |