need some help for sending a msg in python
kyrsa
dtulpan at free.fr
Wed Feb 7 05:08:44 EST 2001
Hi,
I have big problem about this part of the file :
temp_mail.write('From: %s\nTo: %s\n' % (fr, values))
temp_mail.write('MIME-Version: 1.0\n')
temp_mail.write('Content-Type: text/plain; charset=iso-8859-1\n')
temp_mail.write('Content-Transfer-Encoding: 8bit\n')
temp_mail.write("Subject: %s\n" % subject)
temp_mail.write('\n')
currentLine = inputFile.readline()
while (currentLine != ""):
temp_mail.write(currentLine)
currentLine = inputFile.readline()
# Envoi du mail
temp_mail.write('--------------------------------------------------------\n'
)
temp_mail.write('Pour vous desabonner de la liste de diffusion :\n')
temp_mail.write('http://www.domaine.com/listedif/desabon.php3?email='+values
+'\n')
temp_mail.close()
rc = os.system('%s %s < %s' % (sendmail_path, values, temp_mail_name))
when i'm testing it, it's writing :
File "mail_list.py", line 87
temp_mail.write('http://www.domaine.com/listedif/desabon.php3?email='+values
+'\n')
^
SyntaxError: invalid syntax
Can you help me ???
Thx
Kyrsa
More information about the Python-list
mailing list