PHPackages                             glorpen/style-embedder-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. glorpen/style-embedder-bundle

ActiveSymfony-bundle

glorpen/style-embedder-bundle
=============================

Bundle for embedding css style into html style tags for eg. newsletters

v0.1.1(12y ago)0633GPL-3.0PHP

Since Mar 23Pushed 6y ago1 watchersCompare

[ Source](https://github.com/glorpen/GlorpenStyleEmbedderBundle)[ Packagist](https://packagist.org/packages/glorpen/style-embedder-bundle)[ RSS](/packages/glorpen-style-embedder-bundle/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (4)Versions (2)Used By (0)

GlorpenStyleEmbedderBundle
==========================

[](#glorpenstyleembedderbundle)

Parses given CSS styles and applies it to html elements. Embedding is often needed in newsletters - with inline styles it should look good in any browser/client and you don't have to mantain style spaghetti :)

Since css is embedded into style attribute, pseudo selectors are not supported (:hover,:nth-child, etc).

You can use any css selector combination. Multiple selectors will be applied to single element with accounting for css selector specifity, so you can write:

```
* { color: red; }
#myId { color: blue; }
```

How to install
--------------

[](#how-to-install)

- add requirements to composer.json:

```
{
    "require": {
        "glorpen/style-embedder-bundle": "@dev"
    }
}
```

- enable the plugin in your **AppKernel** class

*app/AppKernel.php*

```
