Schnell-Link fuer verkuerzte Umfrage eingefuegt
verbliebene Zeit wird in den letzten zwei Tagen in Stunden angegeben
This commit is contained in:
parent
4084d22f08
commit
cec69f8846
2 changed files with 20 additions and 4 deletions
|
@ -1,4 +1,4 @@
|
|||
#!/usr/bin/env python2.6
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
#
|
||||
|
@ -160,7 +160,8 @@ def send_mail(to_address, from_address, subject, text):
|
|||
use_ssl = use_ssl.lower() in ("1", "true", "yes", "on", "enabled")
|
||||
host = config.get("mail", "host", "localhost")
|
||||
if use_ssl:
|
||||
s = smtplib.SMTP_SSL(host)
|
||||
# see http://bugs.python.org/issue11927 (Python 2.7 uses port 25 instead of 465 by default)
|
||||
s = smtplib.SMTP_SSL(host, port=465)
|
||||
else:
|
||||
s = smtplib.SMTP(host)
|
||||
s.sendmail(from_address, [to_address], msg.as_string())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue