Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

pypm install django-email-html

How to install django-email-html

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install django-email-html
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
Windows (64-bit)
Mac OS X (10.5+)
Linux (32-bit)
0.1.2 Available View build log
Linux (64-bit)
0.1.2 Available View build log
Lastest release
version 0.1.2 on Apr 13th, 2013

# Django Email HTML

[![Build Status](https://travis-ci.org/ramusus/django-email-html.png?branch=master)](https://travis-ci.org/ramusus/django-email-html)

This application can be used for quickly switching all emails of site from plain-text to html. For using it you need to do 2 steps:

  • add email_html to INSTALLED_APPS higher, then other third-part applications;
  • change email templates to html version;

Application substitutes built-in send_mail function by new smart send_mail function.


send_mail(subject, message, from_email, recipient_list, fail_silently=False, auth_user=None, auth_password=None, connection=None)

new one:

send_mail(subject, message, from_email=None, recipient_list=None, fail_silently=False, auth_user=None, auth_password=None, connection=None)

## Few new features:

  • message attribute using for html or plain-test message body. If it contains html, plain-text is generating automatically basing on html body;
  • from_email attribute is not required. By default it will be equal to settings.DEFAULT_FROM_EMAIL;
  • Depending on settings.EMAIL_ADMIN_DUPLICATE all copies of email messages also sending to ADMIN emails (using bcc header);

New function cam be used:

send_mail(subj, html, recipient_list=emails)

## Requirements:

  • BeautifulSoup
  • w3m (for generating plain-text from html)

## Important things:

  • Place email_html application in INSTALLED_APPS before all other applications, which sending emails, that you need to make html based by default;
  • Html body must contains <html> tag, otherwise function would think this is a plain-text body;

Subscribe to package updates

Last updated Apr 13th, 2013

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.