mirror of https://github.com/scrapy/scrapy.git
some email doc improvments
--HG-- extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%40705
This commit is contained in:
parent
09459ed7f7
commit
dfdc04c28c
|
|
@ -1,4 +1,4 @@
|
|||
.. _topics-email:
|
||||
.. _ref-email:
|
||||
|
||||
=============
|
||||
Sending email
|
||||
|
|
@ -29,15 +29,18 @@ MailSender class
|
|||
================
|
||||
|
||||
MailSender is the class used to send emails from Scrapy. It's
|
||||
currently only a warpper over the (IO blocking) smtplib
|
||||
currently only a wrapper over the (IO blocking) `smtplib`_
|
||||
library but it's gonna be ported to Twisted soon.
|
||||
|
||||
.. _smtplib: http://docs.python.org/library/smtplib.html
|
||||
|
||||
.. class:: scrapy.mail.MailSender(smtphost, mailfrom)
|
||||
|
||||
``smtphost`` is a string with the SMTP host to use for sending the emails
|
||||
``smtphost`` is a string with the SMTP host to use for sending the emails.
|
||||
If omitted, :setting:`MAIL_HOST` will be used.
|
||||
|
||||
``mailfrom`` is a string with the email address to use for sending messages
|
||||
(in the ``From:`` header)
|
||||
(in the ``From:`` header). If omitted, :setting:`MAIL_FROM` will be used.
|
||||
|
||||
.. method:: send(to, subject, body, cc=None, attachs=None)
|
||||
|
||||
|
|
|
|||
|
|
@ -441,9 +441,18 @@ MAIL_FROM
|
|||
|
||||
Default: ``'scrapy@localhost'``
|
||||
|
||||
Scope: ``scrapy.mail``
|
||||
Email to use as sender address for sending emails using the :ref:`Scrapy e-mail
|
||||
sending facility <ref-email>`.
|
||||
|
||||
Host to use for sending notification emails from Scrapy.
|
||||
.. setting:: MAIL_HOST
|
||||
|
||||
MAIL_HOST
|
||||
---------
|
||||
|
||||
Default: ``'localhost'``
|
||||
|
||||
Host to use for sending emails using the :ref:`Scrapy e-mail sending facility
|
||||
<ref-email>`.
|
||||
|
||||
.. setting:: MEMDEBUG_ENABLED
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue