H
Hank
Hi,
I have a function that sends mail but I'm finding the number of
characters in the To: field is limited to ~255 characters. This means
that email is sent to only part of the email list.
#recipients is a list of email addresses, greater than 255 characters
in total
header = "To: " + string.join(recipients, "; ") + "\r\n" \
"From: " + "(e-mail address removed)\r\n" \
"Date: " + time.strftime("%A, %B %d, %Y %I:%M %p",
sendTime)+ "\r\n"
"X-Mailer: Automated Test \r\n" \
"Subject: " + subject + "\r\n\r\n"
text = header + mailText
server = smtplib.SMTP('something.something.com')
result = server.sendmail("(e-mail address removed)", recipients, text)
server.quit()
Any help is greatly appreciated.
Thanks
I have a function that sends mail but I'm finding the number of
characters in the To: field is limited to ~255 characters. This means
that email is sent to only part of the email list.
#recipients is a list of email addresses, greater than 255 characters
in total
header = "To: " + string.join(recipients, "; ") + "\r\n" \
"From: " + "(e-mail address removed)\r\n" \
"Date: " + time.strftime("%A, %B %d, %Y %I:%M %p",
sendTime)+ "\r\n"
"X-Mailer: Automated Test \r\n" \
"Subject: " + subject + "\r\n\r\n"
text = header + mailText
server = smtplib.SMTP('something.something.com')
result = server.sendmail("(e-mail address removed)", recipients, text)
server.quit()
Any help is greatly appreciated.
Thanks