By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,890 Members | 1,039 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,890 IT Pros & Developers. It's quick & easy.

i damaged a "Roll my own emailer"

P: n/a
This is the header of the email I am trying to send. My 'ReplyTo' is
not working as planed/

I tried googling thsi and did not get a good answer. I examed the code
before, as suggested and tried the example below. No joy

require("class.phpmailer.php");
$mail = new PHPMailer();
$mail->IsSMTP(); // telling the class to use SMTP
$mail->Host = "smtp.xxxxxxxx.com"; // SMTP server
$mail->Username = "da*********@xxxxxxxx.com";
$mail->Password = "ironnail";
$mail->FromName = "Dave Lemke <dl****@xxxxxxxx.net>";
$mail->From = "Dave Lemke <dl****@xxxxxxxx.net>";
Line 34 $mail->ReplyTo = "dl****@xxxxxxxx.net hc******@goodloops.com
ag*******@hotmail.com da*********@xxxxxxxx.com";
$mail->Cc = "da*********@xxxxxxxx.com";
$mail->Sender = "ag*******@xxxxxxxx.com";
$mail->ReturnReceiptTo = "da*********@xxxxxxxx.com";
$mail->AddAddress(" {$_SERVER['argv'][1]}");


$mail->ReplyTo = "dl****@xxxxxxxx.net", "cr*****@gosodloops.com", "
ag*******@hotmail.com", " da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected ',' in /root/tffwebsite/
membershipmailer/mailsender.php on line 34

$mail->ReplyTo = "dl****@xxxxxxxx.net" " hc******@goodloops.com"
"ag*******@hotmail.com" "da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in /
root/tffwebsite/membershipmailer/mailsender.php on line34

$mail->ReplyTo = 'dl****@xxxxxxxx.net' 'hc******@goodloops.com' '
ag*******@hotmail.com' ' da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in /
root/tffwebsite/membershipmailer/mailsender.php on line34

Earlier this morning I tried several 'Cc' but that did not work. Don't
right now remember if it just did not work or if I got an error.

I can get everything to work if I only use one name at a time. But I
have 320 people to send this Message to and I want all replies to go
to 3 different people and myself.

My brain hurts. Can someone hit me on the head again.

TIA
Dave
Sep 11 '08 #1
Share this Question
Share on Google+
4 Replies


P: n/a
>$mail->ReplyTo = "dl****@xxxxxxxx.net", "cr*****@gosodloops.com", "
>ag*******@hotmail.com", " da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected ',' in /root/tffwebsite/
membershipmailer/mailsender.php on line 34
The string concatenation operator is period, not comma.
Also, you don't want to concatenate those strings as-is: you need
spaces between them in the assembled string.

I suggest:
$mail->ReplyTo = "dl****@xxxxxxxx.net cr*****@gosodloops.com "
.. "ag*******@hotmail.com da*********@xxxxxxxx.com ";

Note trailing spaces (not really required on the last line).

Either that, or put the whole huge string on one line.

Sep 11 '08 #2

P: n/a
Dave Kelly wrote:
This is the header of the email I am trying to send. My 'ReplyTo' is
not working as planed/

I tried googling thsi and did not get a good answer. I examed the code
before, as suggested and tried the example below. No joy

require("class.phpmailer.php");
$mail = new PHPMailer();
$mail->IsSMTP(); // telling the class to use SMTP
$mail->Host = "smtp.xxxxxxxx.com"; // SMTP server
$mail->Username = "da*********@xxxxxxxx.com";
$mail->Password = "ironnail";
$mail->FromName = "Dave Lemke <dl****@xxxxxxxx.net>";
$mail->From = "Dave Lemke <dl****@xxxxxxxx.net>";
Line 34 $mail->ReplyTo = "dl****@xxxxxxxx.net hc******@goodloops.com
ag*******@hotmail.com da*********@xxxxxxxx.com";
$mail->Cc = "da*********@xxxxxxxx.com";
$mail->Sender = "ag*******@xxxxxxxx.com";
$mail->ReturnReceiptTo = "da*********@xxxxxxxx.com";
$mail->AddAddress(" {$_SERVER['argv'][1]}");


$mail->ReplyTo = "dl****@xxxxxxxx.net", "cr*****@gosodloops.com", "
ag*******@hotmail.com", " da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected ',' in /root/tffwebsite/
membershipmailer/mailsender.php on line 34

$mail->ReplyTo = "dl****@xxxxxxxx.net" " hc******@goodloops.com"
"ag*******@hotmail.com" "da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in /
root/tffwebsite/membershipmailer/mailsender.php on line34

$mail->ReplyTo = 'dl****@xxxxxxxx.net' 'hc******@goodloops.com' '
ag*******@hotmail.com' ' da*********@xxxxxxxx.com";
Gives me this error:
Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in /
root/tffwebsite/membershipmailer/mailsender.php on line34

Earlier this morning I tried several 'Cc' but that did not work. Don't
right now remember if it just did not work or if I got an error.

I can get everything to work if I only use one name at a time. But I
have 320 people to send this Message to and I want all replies to go
to 3 different people and myself.

My brain hurts. Can someone hit me on the head again.

TIA
Dave
The ReplyTo is a comma separated list of email addresses. You need the
commas - but everything needs to be within one string, i.e. (pardon the
line wrap)

$mail->ReplyTo = "dl****@xxxxxxxx.net, cr*****@gosodloops.com,
ag*******@hotmail.com, da*********@xxxxxxxx.com";

And BTW - when using example domains, please use example.net,
example.com, etc. Those are specifically reserved for such usage.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Sep 11 '08 #3

P: n/a
On Sep 11, 8:05 am, Jerry Stuckle <jstuck...@attglobal.netwrote:
The ReplyTo is a comma separated list of email addresses. You need the
commas - but everything needs to be within one string, i.e. (pardon the
line wrap)

$mail->ReplyTo = "dle...@xxxxxxxx.net, crof...@gosodloops.com,
aged_s...@hotmail.com, daveekel...@xxxxxxxx.com";

And BTW - when using example domains, please use example.net,
example.com, etc. Those are specifically reserved for such usage.

The line wrap was due to the constraints of the email format.
I tried both examples and neither works. Thanks fo the feedback. I
will work around this problem.

As for 'example.net' I learn something everyday. Thanks for that also.

Dave
Sep 12 '08 #4

P: n/a
Dave Kelly wrote:
On Sep 11, 8:05 am, Jerry Stuckle <jstuck...@attglobal.netwrote:
>The ReplyTo is a comma separated list of email addresses. You need the
commas - but everything needs to be within one string, i.e. (pardon the
line wrap)

$mail->ReplyTo = "dle...@xxxxxxxx.net, crof...@gosodloops.com,
aged_s...@hotmail.com, daveekel...@xxxxxxxx.com";

And BTW - when using example domains, please use example.net,
example.com, etc. Those are specifically reserved for such usage.


The line wrap was due to the constraints of the email format.
I tried both examples and neither works. Thanks fo the feedback. I
will work around this problem.

As for 'example.net' I learn something everyday. Thanks for that also.

Dave
Dave, the code I gave you puts the ReplyTo string in the correct format.
If that's what you're using, your problem lies somewhere else.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Sep 12 '08 #5

This discussion thread is closed

Replies have been disabled for this discussion.