Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Email orders not sending but email order confirmation works


Guest

Recommended Posts

Posted

Hi

 

Both the email orders to the store owners and the email for splut credit card details are not working althougth the email that confirms the order to the customer does work, does anyone have any idea why this is and what i might be able to do to sort it.

 

Thanks

Posted

I to am having the same problem. The customer gets their e-mail confirmation and the vendor does not receive an e-mail. Please help.

 

Mickey

Posted

I'm sure this was working at some point and may have occured because I moved the site recently. I have now reinstalled all files and the problem still exists. I therefore think i have corrupted the db in someway, does anyone know an easy way to check that all tables etc in the database are correct and present.

 

Thanks

Posted

in Adming>>My Store

do you have your email address set into the "send extra order emails to" option?

 

dunno if thats the right way todo it but thats what I had todo to get it to send a copy to me

Posted

you shouldnt have to do it that way, but i have tried it anyhow and it didnt work, thanks anyway

Posted

Double check that you did not put an unescaped single quote in the text of the email that is supposed to be sent. This would cause hte email to not be sent, and you would not get an error.

-------------------------------------------------------------------------------------------------------------------------

NOTE: As of Oct 2006, I'm not as active in this forum as I used to be, but I still work with osC quite a bit.

If you have a question about any of my posts here, your best bet is to contact me though either Email or PM in my profile, and I'll be happy to help.

Posted

no, that hasn't helped either.

 

think I'm going to have a look at the code for catalog/checkout_process.php , if its sending an email to the customer surely i can send that detail to myself as well.

 

Thanks anyhow

Posted

if anyone can explain some of the underneath code i would be very grateful.

 

This is from /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) . "nn";

 if ($order->info['comments']) {

   $email_order .= tep_db_output($order->info['comments']) . "nn";

 }

 $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 . "n" .

                   tep_address_label($customer_id, $sendto, 0, '', "n") . "n";

 }



 $email_order .= "n" . EMAIL_TEXT_BILLING_ADDRESS . "n" .

                 EMAIL_SEPARATOR . "n" .

                 tep_address_label($customer_id, $billto, 0, '', "n") . "nn";

 if (is_object($$payment)) {

   $email_order .= EMAIL_TEXT_PAYMENT_METHOD . "n" .

                   EMAIL_SEPARATOR . "n";

   $payment_class = $$payment;

   $email_order .= $payment_class->title . "nn";

   if ($payment_class->email_footer) {

     $email_order .= $payment_class->email_footer . "nn";

   }

 }

 tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, '');

 

now which is the part that sends to the customer?

 

i take it

tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, '');

 

is supposed to be sending to me, so i will try and swap STORE_OWNER_EMAIL_ADDRESS for my address and see what occurs.

 

Any help or pointers is appreciated

Posted

if anyone can explain some of the underneath code i would be very grateful.

 

This is from /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) . "nn";

 if ($order->info['comments']) {

   $email_order .= tep_db_output($order->info['comments']) . "nn";

 }

 $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 . "n" .

                   tep_address_label($customer_id, $sendto, 0, '', "n") . "n";

 }



 $email_order .= "n" . EMAIL_TEXT_BILLING_ADDRESS . "n" .

                 EMAIL_SEPARATOR . "n" .

                 tep_address_label($customer_id, $billto, 0, '', "n") . "nn";

 if (is_object($$payment)) {

   $email_order .= EMAIL_TEXT_PAYMENT_METHOD . "n" .

                   EMAIL_SEPARATOR . "n";

   $payment_class = $$payment;

   $email_order .= $payment_class->title . "nn";

   if ($payment_class->email_footer) {

     $email_order .= $payment_class->email_footer . "nn";

   }

 }

 tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, '');

 

now which is the part that sends to the customer?

 

i take it

tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, '');

 

is supposed to be sending to me, so i will try and swap STORE_OWNER_EMAIL_ADDRESS for my address and see what occurs.

 

Any help or pointers is appreciated

Posted

i have entered this code

if(isset($order)){

 $TO = "[email protected]";

 $HEADER = "From: [email protected]";

 $HEADER .= "Bcc: $sendtorn";

 $MESSAGE = "This is My Message";

  //send mail - $subject & $contents come from surfer input

  mail($TO, $SUBJECT, $MESSAGE, $HEADER);

  // redirect back to url visitor came from



 }

 

underneath the tep mail that i think sends me confirmation, it doesnt work - even though i have tested on a stand alone page and think it should. Anyone know why this part of the page is not being seen, this is where i suppose my problem lies. will investigate further.

Posted

actually the above code does work, just takes half an hour to come through (which must be something to do with my ISP). I now have a solution with

 

 if(isset($order)){

 $TO = "[email protected]";

 $HEADER = "From: [email protected]";

 $HEADER .= "Bcc: $sendtorn";

 $MESSAGE = ''.nl2br($email_order).'';

  //send mail - $subject & $contents come from surfer input

  mail($TO, $SUBJECT, $MESSAGE, $HEADER);

  // redirect back to url visitor came from



 }

although I get annoying </br> in the message, but at least its a temporary solution.

Posted

Same issue here. I've tried using the "Extra order email", changing the email address to the owners home email (I've read that occasionally a server has an issue with emailing itself), changing the addresses around, checking that email sending is turned on in admin, you name it... no luck. I'm using MS1, and have not done anything fancy outside of the usual setup.

 

Violet

Posted

Cookiebytes

 

try using that code in the message above yours, it needs to entered on the page /catalog/checkout_process.php

around line 263 underneath the line

 

 tep_mail($order->customer['firstname'] . ' ' . $order->customer['lastname'], $order->customer['email_address'], EMAIL_TEXT_SUBJECT, nl2br($email_order), STORE_OWNER, $myEmailAdress, '');

 

its an ugly hack but gets the store working.

Posted

I tried the solution listed and it is not working for me. Anyone else got any tips

  • 2 weeks later...
Posted

I am having email problems as well.

 

The only 'address' or 'field' that is receiving email is the 'send extra orders to' field.

 

Customer does not receive an email re: order and neither does the store admin.

 

Any solutions out there?

Posted

Found this thread - I'm having the same problem.

 

When customers place orders they get their confirmation e-mail, but no e-mails are sent to either the main address or the "send extra order e-mails to"

 

hopefully someone can figure this out

Radio Shack: "You've got questions, we've got batteries."
Posted

For what it's worth - I just created an account using an e-mail address at the same domain as the shop and the e-mail arrived just fine. Still not e-mail to the main account though.

Radio Shack: "You've got questions, we've got batteries."
Posted
The only 'address' or 'field' that is receiving email is the 'send extra orders to' field.
Is the address in the send extra orders to field local to the server? Some servers won't handle outgoing mail. In those cases, you need to use the SMTP with authentication contribution to use an external mail server for sending.

 

Hth,

Matt

Posted

I've installed that SMTP Authentication Module - but no joy - this is the problem

 

Fatal error: Cannot redeclare class smtp in /home/virtual/site2/fst/var/www/html/includes/classes/class.smtp.inc on line 12

 

 

I've seen a number of other posts for people who have this problem, but no solution out and about yet.

Posted

My problem is similar:

 

The purchaser is getting their email, but the extra order emails address is not getting their email. Or, the store doesn't recieve an email for the order. The order is properly showing up in the Customers section of admin under Orders.

 

I have the set in Admin, the following:

 

Send Extra Order Emails To Order <[email protected]>

 

and

 

E-Mail Transport Method sendmail

 

 

 

 

Shouldn't this bit of code in catalogcheckout_process.php work?

// 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, '');

 }

Posted

This is the email I sent to my hosting company...........

 

I am using osCommerce for my shopping cart. It's feature is

to send the confirmed order to the purchaser and to the

address designated in extra order emails. The purchaser is

getting their email, but the extra order emails address is

not getting their email. I think my problem lies with this

option in osCommerce.

 

E-mail transport method:

 

Defines if this server uses a local connection to sendmail

or uses an SMTP connection via TCP/IP. Servers running on

Windows and MacOS should change this setting to SMTP.

 

Choices are sendmail and smtp.

 

My question is, should I be choosing smtp or sendmail? I

currently have it set to sendmail.

 

Their response..............

 

CGI scripts run in accounts should use /usr/sbin/sendmail to

deliver e-mails. SMTP cannot be used as a delivery method.

 

It sounds like you may want to contact the maker of this shopping cart

product in order to inquire further about what might be wrong.

 

 

 

Lots of help they were. I still am having the problem of only the customer is getting the email about the order. Why isn't the store_owner getting the email? See my above post for more details.

 

Need help on this one!! :?

  • 2 weeks later...
Posted

Has anyone posted here managed to solve

the E mail not sending issue.

 

recently I tried to install Feedback request Contribution

which automatically sends a message to the visitor

and got the following reply from my HOST when I

requested help.

+++++++++++++++++++=

What is happening is your script requires PHP as a cgi module, which

is not available. We have it available as an Apache API right now.

 

Maybe you can check with the software developer if the scripts can run

via the Apache API (ie: a web browser). You can use wget to run them

then if that is possible.

 

++++++++++++++++++++++++++++=

My cart was sending messages before and now

it has stopped altogether except for Manual from the ADMIN

 

I am keen to know if anyone has found a solution

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...