Last active
April 10, 2016 18:00
-
-
Save dogancankilment/30482890cdae45b9bc03fc3bd45bb09c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# django.core.mail using your base settings.py at your project | |
# You must add in to your settings.py email smtp configuration | |
# you can look my mail-sender-settings.py | |
# https://gist.github.com/dogancankilment/2ddf7f5363733bbef471dcaf15bdfc31#file-mail-sender-settings-py | |
from django.core.mail import send_mail | |
def mail_sender(): | |
send_mail('Subject here', | |
'Here is the message.', | |
'from@example.com', | |
['to@example.com'], | |
fail_silently=False) | |
if __name__ == '__main__': | |
mail_sender() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment