ljweb Posted August 7, 2003 Posted August 7, 2003 How do i get the customers phone number to show up in the email that the store owner gets? Is this a configuration thing in the admin area (i cant find anything..) or do i have to edit a file. Please help.
Ajeh Posted August 7, 2003 Posted August 7, 2003 Edit the checkout_process.php // BOF: WebMakers.com Added: Include Order # in Subject and name, phone and email in body to extra emails // send emails to other people if (SEND_EXTRA_ORDER_EMAILS_TO != '') { $email_order = $order->customer['firstname'] . ' ' . $order->customer['lastname'] . "n" . 'Telephone: ' . $order->customer['telephone'] . "n" . $order->customer['email_address'] . "nn" . $email_order; tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, 'NEW - ' . EMAIL_TEXT_SUBJECT . ' #' . $insert_id, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS); }
SkinEFX Posted December 21, 2003 Posted December 21, 2003 This looks great, but which checkout_process.php file do I put this in? I tried the one in catalog/ but nothing happened. Using version 2.2
beercan Posted December 21, 2003 Posted December 21, 2003 I tried this code and it works great. It goes in the file in catalog. make sure you overwrite or comment out the line it is replaceing (near the bottom) as always backup before making changes. BC
bethbenjamin Posted January 7, 2004 Posted January 7, 2004 This was a great idea. I added it to my store and it works like a charm. Kudos Linda - another great solution.
vela13 Posted January 14, 2004 Posted January 14, 2004 Hi there, This goes out to anyone who has got this to work.. I also want the phone number and customers email sending in the order confirmation email. I am on an older release (about Jan 2002). I currently get the email by way of adding my email add in admin "send extra order emails" bit. I have tried the code that linda suggested but it only shows the word "Telephone" at the top of the order email to me. It also send an extra email to me (I get two) here is the code from my /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 ($comments) { $email_order .= $comments . "\n\n"; } $email_order .= EMAIL_TEXT_PRODUCTS . "\n" . EMAIL_SEPARATOR . "\n" . $products_ordered . EMAIL_SEPARATOR . "\n" . EMAIL_TEXT_SUBTOTAL . ' ' . $currencies->format($cart->show_total()) . "\n" . EMAIL_TEXT_TAX . $currencies->format($total_tax) . "\n"; if ($GLOBALS['shipping_cost'] > 0) { $email_order .= EMAIL_TEXT_SHIPPING . ' ' . $currencies->format($GLOBALS['shipping_cost']) . ' ' . TEXT_EMAIL_VIA . ' ' . $GLOBALS['shipping_method'] . "\n"; } if (TAX_INCLUDE == true) { $email_order .= EMAIL_TEXT_TOTAL . ' ' . $currencies->format($cart->show_total() + $GLOBALS['shipping_cost']) . "\n\n"; } else { $email_order .= EMAIL_TEXT_TOTAL . ' ' . $currencies->format($cart->show_total() + $total_tax + $GLOBALS['shipping_cost']) . "\n\n"; } $email_order .= EMAIL_TEXT_DELIVERY_ADDRESS . "\n" . EMAIL_SEPARATOR . "\n" . tep_address_label($customer_id, $sendto, 0, '', "\n") . "\n\n"; if (is_object($$payment)) { $email_order .= EMAIL_TEXT_PAYMENT_METHOD . "\n" . EMAIL_SEPARATOR . "\n"; $email_order .= $$payment->title . "\n\n"; if ($$payment->email_footer) { $email_order .= $$payment->email_footer . "\n\n"; } } tep_mail($customer_name, $customer_values['customers_email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, ''); // send emails to other people if (SEND_EXTRA_ORDER_EMAILS_TO != '') { tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, ''); }
stefano Posted January 16, 2004 Posted January 16, 2004 Hi, I also had the necessity to retrieve more possible information, in comparison to the original version, because I had the need to contact the clients through telephone or email at the right moment, and the only way was to enter every time the administrative panel and to look for the information going up again from the order. My solution is: \catalog\checkout_process.php orig. if ($order->content_type != 'virtual') { $email_order .= "\n" . EMAIL_TEXT_DELIVERY_ADDRESS . "\n" . EMAIL_SEPARATOR . "\n" . tep_address_label($customer_id, $sendto, 0, '', "\n") . "\n"; } \catalog\checkout_process.php modif. if ($order->content_type != 'virtual') { $email_order .= "\n" . EMAIL_TEXT_DELIVERY_ADDRESS . "\n" . EMAIL_SEPARATOR . "\n" . EMAIL_TEXT_MAIL . $order->customer['email_address'] . "\n" . EMAIL_SEPARATOR . "\n" . tep_address_label($customer_id, $sendto, 0, '', "\n") . EMAIL_TEXT_PHONE . $order->customer['telephone']. "\n"; } In more, the following lines, must be added \catalog\includes\languages\(your language)\checkout_process.php define('EMAIL_TEXT_MAIL', 'Email: '); define('EMAIL_TEXT_PHONE', 'Telefono: '); Bye Stefano http://www.oscommerceitalia.com
vela13 Posted January 16, 2004 Posted January 16, 2004 thank you for the reply - i will give it a try!!!!
FFK Posted November 10, 2004 Posted November 10, 2004 Thanks Ajeh Using this, and it works greate. Can you also have the total Weight of the order show in the eMail.... Best regards PK
TorontoON Posted November 16, 2004 Posted November 16, 2004 Thanks Linda. It worked fine for me, much appreciated. :) :thumbsup:
ireader Posted November 17, 2004 Posted November 17, 2004 Hi Linda, while were on the subject, I have used this piece of code ok, works fine when putting order_id in the email_subject :thumbsup: But I cannot get it to display the products_model info in the email_subject, what am I missing Linda or anyone, sure would appreciate a tip in the right direction, Thanks all Ian
Recommended Posts
Archived
This topic is now archived and is closed to further replies.