Fixed #4163 -- Added some "quick notes" documentation about the configuration

variables required to send email. Thanks, Karen Tracey.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5111 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Malcolm Tredinnick 2007-04-27 14:25:05 +00:00
parent 33ce769786
commit 1c2fdf1ebd
2 changed files with 15 additions and 4 deletions

View File

@ -19,13 +19,23 @@ In two lines::
send_mail('Subject here', 'Here is the message.', 'from@example.com', send_mail('Subject here', 'Here is the message.', 'from@example.com',
['to@example.com'], fail_silently=False) ['to@example.com'], fail_silently=False)
Mail will be sent using the SMTP host and port specified in the `EMAIL_HOST`_
and `EMAIL_PORT`_ settings. The `EMAIL_HOST_USER`_ and `EMAIL_HOST_PASSWORD`_
settings, if set, will be used to authenticate to the
SMTP server.
.. note:: .. note::
The character set of email sent with ``django.core.mail`` will be set to The character set of email sent with ``django.core.mail`` will be set to
the value of your `DEFAULT_CHARSET setting`_. the value of your `DEFAULT_CHARSET setting`_.
.. _DEFAULT_CHARSET setting: ../settings/#DEFAULT_CHARSET .. _DEFAULT_CHARSET setting: ../settings/#DEFAULT_CHARSET
.. _EMAIL_HOST: ../settings/#EMAIL_HOST
.. _EMAIL_PORT: ../settings/#EMAIL_PORT
.. _EMAIL_HOST_USER: ../settings/#EMAIL_HOST_USER
.. _EMAIL_HOST_PASSWORD: ../settings/#EMAIL_HOST_PASSWORD
send_mail() send_mail()
=========== ===========

View File

@ -395,8 +395,9 @@ EMAIL_HOST_PASSWORD
Default: ``''`` (Empty string) Default: ``''`` (Empty string)
Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty, Password to use for the SMTP server defined in ``EMAIL_HOST``. This setting is
Django won't attempt authentication. used in conjunction with EMAIL_HOST_USER when authenticating to the SMTP server.
If either of these settings is empty, Django won't attempt authenticaion.
See also ``EMAIL_HOST_USER``. See also ``EMAIL_HOST_USER``.