Metadata-Version: 1.0
Name: premailer
Version: 1.3
Summary: Turns CSS blocks into style attributes
Home-page: http://www.peterbe.com/plog/premailer.py
Author: Peter Bengtsson
Author-email: peter@fry-it.com
License: Python
Download-URL: http://pypi.python.org/pypi/premailer/
Description: premailer
        =========
        
        
        Turns CSS blocks into style attributes
        --------------------------------------
        
        When you send HTML emails you can't used style tags but instead you
        have to put inline `style` attributes on every element. So from this::
        
        <html>
        <style type="text/css">
        p { color:red;}
        </style>
        <p>Hej</p>
        </html>
        
        You want this::
        
        <html>
        <p style="color:red">Hej</p>
        </html>
        
        
        premailer does this. It parses an HTML page, looks up `style` blocks
        and parses the CSS. It then uses the `lxml.html` parser to modify the
        DOM tree of the page accordingly.
        
        
        Turning relative URLs into absolute URLs
        ----------------------------------------
        
        Another thing premailer can do for you is to turn relative URLs (e.g.
        "/some/page.html" into "http://www.peterbe.com/some/page.html"). It
        does this to all `href` and `src` attributes that don't have a `://`
        part in it. For example, turning this::
        
        <html>
        <body>
        <a href="/">Home</a>
        <a href="page.html">Page</a>
        <a href="http://crosstips.org">External</a>
        <img src="/folder/">Folder</a>
        </body>
        </html>
        
        Into this::
        
        <html>
        <body>
        <a href="http://www.peterbe.com/">Home</a>
        <a href="http://www.peterbe.com/page.html">Page</a>
        <a href="http://crosstips.org">External</a>
        <img src="http://www.peterbe.com/folder/">Folder</a>
        </body>
        </html>
        
        
Keywords: html lxml email mail style
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Other Environment
Classifier: Environment :: Web Environment
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Python Software Foundation License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Topic :: Communications
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Topic :: Other/Nonlisted Topic
Classifier: Topic :: Software Development :: Libraries :: Python Modules
