[thelist] Double Emails with PHPmail

Rob Smith rob.smith at THERMON.com
Tue Jul 15 09:06:17 CDT 2003

Hi list,

I'm having a small problem with a self-developed PHP shopping cart system.
As of right now, it works great, but it's sending the notification emails

Once the order is ready, all required fields are filled, a correct email
address is provided, a PHP-e-mail is sent to me telling me a new order is
ready, and another email is sent to the customer telling them I'm working to
fill the order. Typical.

At best here's what the (psuedo)code looks like:

 if ($required_fields == "Yes" && $News == "") {
   echo $sender . " " . $subject . " " . $message . " " . $headers .
    if ($Email == "Good") {
      echo $sender2 . " " . $subject2 . " " . $message2 . " " . $headers2;

my at email.com Test. This is a test of the PHP-e-mail system. (some header

myother at email.com Wow. I can see my house from hereeeeeee. (some more header

Yet I receive the first email twice. The date/time sent are identical on
both emails as well as the second emails. From what I write here, it sounds
like I should see as output

Email 1

Email 2
Email 1

Email 2

...but I don't. Any ideas?


More information about the thelist mailing list