asiandivergal Posted March 12, 2007 Posted March 12, 2007 Hi there, I am having problems loading my checkout page (checkout_process.php) after I made amendments to the "order process" email which customers will receive after each new order. I changed the subject heading of the order confirmation email, and added in the email address to the delivery address of the customer. Here are the files I edited: 1) catalog/checkout_process.php: // lets start with the email confirmation $email_order = STORE_NAME . "\n" . EMAIL_SEPARATOR . "\n" . EMAIL_TEXT_ORDER_NUMBER . ' ' . $insert_id . "\n" . EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" . EMAIL_TEXT_DATE_ORDERED . ' ' . strftime(DATE_FORMAT_LONG) . "\n\n"; if ($order->info['comments']) { $email_order .= tep_db_output($order->info['comments']) . "\n\n"; } $email_order .= EMAIL_TEXT_PRODUCTS . "\n" . EMAIL_SEPARATOR . "\n" . $products_ordered . EMAIL_SEPARATOR . "\n"; for ($i=0, $n=sizeof($order_totals); $i<$n; $i++) { $email_order .= strip_tags($order_totals[$i]['title']) . ' ' . strip_tags($order_totals[$i]['text']) . "\n"; } if ($order->content_type != 'virtual') { $email_order .= "\n" . EMAIL_TEXT_DELIVERY_ADDRESS . "\n" . EMAIL_SEPARATOR . "\nemail: " .$order->customer['email_address']. "\n" . tep_address_label($customer_id, $sendto, 0, '', "\n") . "\n"; } $email_order .= "\n" . EMAIL_TEXT_BILLING_ADDRESS . "\n" . EMAIL_SEPARATOR . "\nemail: " .$order->customer['email_address']. "\n" . tep_address_label($customer_id, $billto, 0, '', "\n") . "\n\n"; if (is_object($$payment)) { $email_order .= EMAIL_TEXT_PAYMENT_METHOD . "\n" . EMAIL_SEPARATOR . "\n"; $payment_class = $$payment; $email_order .= $payment_class->title . "\n\n"; if ($payment_class->email_footer) { $email_order .= $payment_class->email_footer . "\n\n"; } } tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, Order:".$insert_id, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); And here is the other file I edited: 2) catalog/includes/languages/engligh/checkout_process.php define('EMAIL_TEXT_SUBJECT', 'STORE_NAME - Your Product Purchase'); define('EMAIL_TEXT_ORDER_NUMBER', 'Order Number:'); define('EMAIL_TEXT_INVOICE_URL', 'Detailed Invoice:'); define('EMAIL_TEXT_DATE_ORDERED', 'Date Ordered:'); define('EMAIL_TEXT_PRODUCTS', 'Products'); define('EMAIL_TEXT_SUBTOTAL', 'Sub-Total:'); define('EMAIL_TEXT_TAX', 'Tax: '); define('EMAIL_TEXT_SHIPPING', 'Shipping: '); define('EMAIL_TEXT_TOTAL', 'Total: '); define('EMAIL_TEXT_DELIVERY_ADDRESS', 'Delivery Address'); define('EMAIL_TEXT_BILLING_ADDRESS', 'Billing Address'); define('EMAIL_TEXT_PAYMENT_METHOD', 'Payment Method'); define('EMAIL_SEPARATOR', '------------------------------------------------------'); define('TEXT_EMAIL_VIA', 'Here I have added my own additional text with simple HTML coding for paragraph breaks'); ?> Can someone kindly inform me if I have done something wrong, as now my checkout page fails to load? Thank you in advance!
asiandivergal Posted March 15, 2007 Author Posted March 15, 2007 Hi there, I am having problems loading my checkout page (checkout_process.php) after I made amendments to the "order process" email which customers will receive after each new order. I changed the subject heading of the order confirmation email, and added in the email address to the delivery address of the customer. Here are the files I edited: 1) catalog/checkout_process.php: // lets start with the email confirmation $email_order = STORE_NAME . "\n" . EMAIL_SEPARATOR . "\n" . EMAIL_TEXT_ORDER_NUMBER . ' ' . $insert_id . "\n" . EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" . EMAIL_TEXT_DATE_ORDERED . ' ' . strftime(DATE_FORMAT_LONG) . "\n\n"; if ($order->info['comments']) { $email_order .= tep_db_output($order->info['comments']) . "\n\n"; } $email_order .= EMAIL_TEXT_PRODUCTS . "\n" . EMAIL_SEPARATOR . "\n" . $products_ordered . EMAIL_SEPARATOR . "\n"; for ($i=0, $n=sizeof($order_totals); $i<$n; $i++) { $email_order .= strip_tags($order_totals[$i]['title']) . ' ' . strip_tags($order_totals[$i]['text']) . "\n"; } if ($order->content_type != 'virtual') { $email_order .= "\n" . EMAIL_TEXT_DELIVERY_ADDRESS . "\n" . EMAIL_SEPARATOR . "\nemail: " .$order->customer['email_address']. "\n" . tep_address_label($customer_id, $sendto, 0, '', "\n") . "\n"; } $email_order .= "\n" . EMAIL_TEXT_BILLING_ADDRESS . "\n" . EMAIL_SEPARATOR . "\nemail: " .$order->customer['email_address']. "\n" . tep_address_label($customer_id, $billto, 0, '', "\n") . "\n\n"; if (is_object($$payment)) { $email_order .= EMAIL_TEXT_PAYMENT_METHOD . "\n" . EMAIL_SEPARATOR . "\n"; $payment_class = $$payment; $email_order .= $payment_class->title . "\n\n"; if ($payment_class->email_footer) { $email_order .= $payment_class->email_footer . "\n\n"; } } tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, Order:".$insert_id, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); And here is the other file I edited: 2) catalog/includes/languages/engligh/checkout_process.php define('EMAIL_TEXT_SUBJECT', 'STORE_NAME - Your Product Purchase'); define('EMAIL_TEXT_ORDER_NUMBER', 'Order Number:'); define('EMAIL_TEXT_INVOICE_URL', 'Detailed Invoice:'); define('EMAIL_TEXT_DATE_ORDERED', 'Date Ordered:'); define('EMAIL_TEXT_PRODUCTS', 'Products'); define('EMAIL_TEXT_SUBTOTAL', 'Sub-Total:'); define('EMAIL_TEXT_TAX', 'Tax: '); define('EMAIL_TEXT_SHIPPING', 'Shipping: '); define('EMAIL_TEXT_TOTAL', 'Total: '); define('EMAIL_TEXT_DELIVERY_ADDRESS', 'Delivery Address'); define('EMAIL_TEXT_BILLING_ADDRESS', 'Billing Address'); define('EMAIL_TEXT_PAYMENT_METHOD', 'Payment Method'); define('EMAIL_SEPARATOR', '------------------------------------------------------'); define('TEXT_EMAIL_VIA', 'Here I have added my own additional text with simple HTML coding for paragraph breaks'); ?> Can someone kindly inform me if I have done something wrong, as now my checkout page fails to load? Thank you in advance! Really disappointed that no one had replied after so long, but that's ok, after many many days of trying to resolve this, I uploaded the original file to overwrite this and it's now working fine. Guess it's the coding part somehow.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.