Prepare HTML for email; embedd CSS to inline.
Project description
python-premailer converts HTML with style tags into HTML with inline style attributes; gmail won’t render nice without it!
I made it so I could send colorized git diffs of func-inventory around…
- Use:
sudo pip install python-premailer ### from pypremailer import Premailer
html = sys.stdin.read() premailer = Premailer(html) inlined_html = premailer.premail() print inlined_html
Excuses, excuses
This definitely already exists in pypi under the name ‘premailer’, but I wanted to reimplement it without the use of lxml.
Check it out! http://pypi.python.org/pypi/premailer
Inspired by
Emogrifier (php): http://www.pelagodesign.com/sidecar/emogrifier/
Premailer (ruby): http://premailer.dialect.ca/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file python-premailer-0.5.1.tar.gz
.
File metadata
- Download URL: python-premailer-0.5.1.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00e22c563af55fdcd669b45d685dd1589a0109b7eed7747058448f1849570aed |
|
MD5 | 2b67d2c0c628b1a9a9a7ad85cbdea823 |
|
BLAKE2b-256 | 7372edd6a121ea99dbcf846abbacd3d7f541b116390587999906cac24a484a64 |