from django.core import mail
email = mail.EmailMessage('Hello', 'Body goes here', 'from@',
['to@'], connection=connection)
from django.template.loader import render_to_string
print render_to_string('tpl.html', {})
from django.core.mail import EmailMessage
def custom_send_email(to_list, subject, message, sender="Ololo <noreply@ololo.com>"):
msg = EmailMessage(subject, message, sender, to_list)
msg.content_subtype = "html" # Main content is now text/html
return msg.send()