我正在尝试从django网络应用发送电子邮件。我使用了以下
from django.core.mail import send_mail
send_mail('test email', 'hello world', 'your@email.com', ['aman.kumar@thoughts2binary.com'])
我的设置是
DEFAULT_FROM_EMAIL = 'support@indianangelnetwork.com'
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_HOST = 'smtp.gmail.com'
EMAIL_PORT = 587
EMAIL_USE_TLS = True
EMAIL_HOST_USER = 'support@indianangelnetwork.com'
EMAIL_HOST_PASSWORD = 'XXXXXXXXXX'
我总是从“support@indianangelnetwork.com”收到邮件。虽然我传递了send_from值。