473,498 Members | 1,704 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Blind carbon copy

I am running into a strange problem with blind carbon copy. I specify two
addresses, one for the sendto and one for the bcc (both are mine). It
sends two emails, but BOTH are to the sendto address. Here it is:

$from = "me@third.com";
$subject = "testing";
$message = "A set of text";
$sendTo = "me@first.com";
$bcc = "me@second.com";
$message = wordwrap($message, 70);
$headers = 'From: ' . $from . "\r\n" . 'Reply-To: ' . $from . "\r\n";
$headers .= 'Bcc: ' . $bcc . "\r\n";
$headers .= 'X-Mailer: PHP/' . phpversion();
mail($sendTo, $subject, $message, $headers);
I get two emails at me@first.com. If I switch the two addresses (setting
$sendTo to be me@second.com and $bcc to be me@first.com, then I get two
emails at me@second.com.

What is going on here?

Shelly
Oct 27 '06 #1
5 2099
Shelly wrote:
I am running into a strange problem with blind carbon copy. I specify two
addresses, one for the sendto and one for the bcc (both are mine). It
sends two emails, but BOTH are to the sendto address. Here it is:

$from = "me@third.com";
$subject = "testing";
$message = "A set of text";
$sendTo = "me@first.com";
$bcc = "me@second.com";
$message = wordwrap($message, 70);
$headers = 'From: ' . $from . "\r\n" . 'Reply-To: ' . $from . "\r\n";
$headers .= 'Bcc: ' . $bcc . "\r\n";
$headers .= 'X-Mailer: PHP/' . phpversion();
mail($sendTo, $subject, $message, $headers);
I get two emails at me@first.com. If I switch the two addresses (setting
$sendTo to be me@second.com and $bcc to be me@first.com, then I get two
emails at me@second.com.

What is going on here?

Shelly

I think you'll find this is working, just that the bcc address is
correctly not being displayed. If you look at the headers for the
received emails, you should see they have gone to the right addresses.
Oct 27 '06 #2

"Jeff Paffett" <jp******@otenet.grwrote in message
news:eh**********@mouse.otenet.gr...
Shelly wrote:
>I am running into a strange problem with blind carbon copy. I specify
two addresses, one for the sendto and one for the bcc (both are mine).
It sends two emails, but BOTH are to the sendto address. Here it is:

$from = "me@third.com";
$subject = "testing";
$message = "A set of text";
$sendTo = "me@first.com";
$bcc = "me@second.com";
$message = wordwrap($message, 70);
$headers = 'From: ' . $from . "\r\n" . 'Reply-To: ' . $from . "\r\n";
$headers .= 'Bcc: ' . $bcc . "\r\n";
$headers .= 'X-Mailer: PHP/' . phpversion();
mail($sendTo, $subject, $message, $headers);
I get two emails at me@first.com. If I switch the two addresses (setting
$sendTo to be me@second.com and $bcc to be me@first.com, then I get two
emails at me@second.com.

What is going on here?

Shelly

I think you'll find this is working, just that the bcc address is
correctly not being displayed. If you look at the headers for the received
emails, you should see they have gone to the right addresses.
The headers are for the two are virtually identical, but I think I see what
you mean. I am getting two, one by each route, but the "To:" displays the
same for both and the bcc doesn't show at all (as it shouldn't). This would
explain why I am getting two, and yet it appears as if both are being sent
to the same address. The only differences between the two headers is that
in one the addresses are all encased in brackets while in the other they are
not (see below)

To: <me@first.com>
Subject: new test
From: <se****@his.com>
Reply-To: <se****@his.com>
X-Mailer: PHP/5.1.2
Message-Id: <20***********************@euclid.dreamhost.com>
Date: Thu, 26 Oct 2006 18:56:29 -0700 (PDT)

To: me@first.com
Subject: new test
From: se****@his.com
Reply-To: se****@his.com
X-Mailer: PHP/5.1.2
Message-Id: <20***********************@euclid.dreamhost.com>
Date: Thu, 26 Oct 2006 18:56:29 -0700 (PDT)

Is that what you meant?

Shelly

Oct 27 '06 #3
On Fri, 27 Oct 2006 02:09:44 GMT, "Shelly"
<sh************@asap-consult.comwrote:
>I am running into a strange problem with blind carbon copy. I specify two
addresses, one for the sendto and one for the bcc (both are mine). It
sends two emails, but BOTH are to the sendto address.
If you mean that both emails have the same "To: " header, that's quite
normal. If you mean that both emails go to the same mailbox, and the
other mailbox does not receive a copy, that's not normal, but doesn't
appear to be the fault of your code.

hth

-
Remove mypants to email.
<http://www.shaunc.com/>
Oct 28 '06 #4
Shelly wrote:
"Jeff Paffett" <jp******@otenet.grwrote in message
news:eh**********@mouse.otenet.gr...
>Shelly wrote:
>>I am running into a strange problem with blind carbon copy. I specify
two addresses, one for the sendto and one for the bcc (both are mine).
It sends two emails, but BOTH are to the sendto address. Here it is:

$from = "me@third.com";
$subject = "testing";
$message = "A set of text";
$sendTo = "me@first.com";
$bcc = "me@second.com";
$message = wordwrap($message, 70);
$headers = 'From: ' . $from . "\r\n" . 'Reply-To: ' . $from . "\r\n";
$headers .= 'Bcc: ' . $bcc . "\r\n";
$headers .= 'X-Mailer: PHP/' . phpversion();
mail($sendTo, $subject, $message, $headers);
I get two emails at me@first.com. If I switch the two addresses (setting
$sendTo to be me@second.com and $bcc to be me@first.com, then I get two
emails at me@second.com.

What is going on here?

Shelly

I think you'll find this is working, just that the bcc address is
correctly not being displayed. If you look at the headers for the received
emails, you should see they have gone to the right addresses.

The headers are for the two are virtually identical, but I think I see what
you mean. I am getting two, one by each route, but the "To:" displays the
same for both and the bcc doesn't show at all (as it shouldn't). This would
explain why I am getting two, and yet it appears as if both are being sent
to the same address. The only differences between the two headers is that
in one the addresses are all encased in brackets while in the other they are
not (see below)

To: <me@first.com>
Subject: new test
From: <se****@his.com>
Reply-To: <se****@his.com>
X-Mailer: PHP/5.1.2
Message-Id: <20***********************@euclid.dreamhost.com>
Date: Thu, 26 Oct 2006 18:56:29 -0700 (PDT)

To: me@first.com
Subject: new test
From: se****@his.com
Reply-To: se****@his.com
X-Mailer: PHP/5.1.2
Message-Id: <20***********************@euclid.dreamhost.com>
Date: Thu, 26 Oct 2006 18:56:29 -0700 (PDT)

Is that what you meant?

Shelly
I don't think your email program is displaying the full headers, there's
a Delivered to: field in mine. But they will appear to be delivered to
the same address, yes.
Oct 29 '06 #5
Jeff Paffett <jp******@otenet.grwrote:
>
I don't think your email program is displaying the full headers, there's
a Delivered to: field in mine. But they will appear to be delivered to
the same address, yes.
"Delivered-To:" is a not a standard header. Your mail server is adding
that to help with spam filtering. Some mail servers call it something like
"X-Envelope-To:".
--
Tim Roberts, ti**@probo.com
Providenza & Boekelheide, Inc.
Oct 29 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
1978
by: Hats | last post by:
Catholic Exorcism Failed Exorcism: The Blind Leading The Blind Subject: Re: Catholic Exorcisms Date: 1997/10/12 SEVERAL EXORCISMS
4
1967
by: Zachary | last post by:
Hello, I'm a blind non-programmer trying to learn Python. I've got python 2.3 for windows, but the problem is that Idle doesn't seem to work two well with my screen reading program. Is notepad,...
1
1659
by: fortepianissimo | last post by:
This is a question only relevant to Mac OS X. Could someone offer a simple example how to use Carbon.File module (perhaps Alias.FSResolveAlias()?) to resolve an alias? Basically I'd like to load...
0
2067
by: Hats | last post by:
Catholic Exorcism Failed Exorcism: The Blind Leading The Blind Subject: Re: Catholic Exorcisms Date: 1997/10/12 SEVERAL EXORCISMS...
0
1266
by: Ringo | last post by:
Catholic Exorcism Failed Exorcism: The Blind Leading The Blind Subject: Re: Catholic Exorcisms Date: 1997/10/12 SEVERAL EXORCISMS
2
2767
by: donbro | last post by:
If my read of the extension source (Mac/Modules/file/_Filemodule.c) is correct, the parameter sizes specified for data and resource file sizes are UInt32 where they should be UInt64. In both OS9...
3
1427
by: kitty | last post by:
Hi, Iam using the Carbon framework to read data from XML files, but it does not read values placed inside curly braces {}. Example: <output>{property}</output> I have tried using numeric...
14
4402
by: andreyvul | last post by:
g++ says a reinterpret cast from void* is disallowed; however, all I'm trying to do is de-capsulate a void* argument that holds the pointer to a class (and static_cast forces cast constructor) any...
8
4963
by: blakerrr | last post by:
Hi All, Is it possible to create a carbon-copy of a table using VBA? I have a table called 'Junction' that stores the structure of a machines assemblies and subassemblies, and I need to create a...
0
7002
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7205
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6887
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7379
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5462
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4910
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3085
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1419
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
656
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.