2017 © Pedro Peláez
 

library css-to-inline-styles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

image

tijsverkoyen/css-to-inline-styles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  • Monday, November 27, 2017
  • by tijsverkoyen
  • Repository
  • 50 Watchers
  • 3550 Stars
  • 22,970,158 Installations
  • PHP
  • 123 Dependents
  • 2 Suggesters
  • 155 Forks
  • 10 Open issues
  • 21 Versions
  • 14 % Grown

The README.md

CssToInlineStyles class

CI, (*1)

About

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails., (*2)

Installation

The recommended installation way is through Composer., (*3)

$ composer require tijsverkoyen/css-to-inline-styles

Example

use TijsVerkoyen\CssToInlineStyles\CssToInlineStyles;

// create instance
$cssToInlineStyles = new CssToInlineStyles();

$html = file_get_contents(__DIR__ . '/examples/sumo/index.htm');
$css = file_get_contents(__DIR__ . '/examples/sumo/style.css');

// output
echo $cssToInlineStyles->convert(
    $html,
    $css
);

Known issues

  • no support for pseudo selectors
  • no support for css-escapes
  • UTF-8 charset is not always detected correctly. Make sure you set the charset to UTF-8 using the following meta-tag in the head: <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />. (Note: using <meta charset="UTF-8"> does NOT work!)

Sites using this class

The Versions

27/11 2017

dev-master

9999999-dev https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Tijs Verkoyen

27/11 2017

2.2.1

2.2.1.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Tijs Verkoyen

20/09 2016

2.2.0

2.2.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Tijs Verkoyen

05/09 2016

2.1.0

2.1.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Tijs Verkoyen

23/02 2016

2.0.0

2.0.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD-3-Clause

The Requires

 

The Development Requires

by Tijs Verkoyen

08/12 2015

1.5.5

1.5.5.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

The Development Requires

by Tijs Verkoyen

01/04 2015

1.5.4

1.5.4.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

The Development Requires

by Tijs Verkoyen

01/04 2015

1.5.3

1.5.3.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

The Development Requires

by Tijs Verkoyen

01/08 2014

1.5.2

1.5.2.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

The Development Requires

by Tijs Verkoyen

25/07 2014

1.5.1

1.5.1.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

25/07 2014

1.5.0

1.5.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

25/07 2014

1.4.4

1.4.4.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

25/07 2014

1.4.3

1.4.3.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

25/07 2014

1.4.2

1.4.2.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

18/07 2014

1.4.1

1.4.1.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

18/07 2014

1.4.0

1.4.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

 

by Tijs Verkoyen

05/05 2014

1.3.0

1.3.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

  • php >=5.3.0

 

by Tijs Verkoyen

09/02 2013

1.2.1

1.2.1.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

  • php >=5.3.0

 

by Tijs Verkoyen

09/02 2013

1.2.0

1.2.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

  • php >=5.3.0

 

by Tijs Verkoyen

13/10 2012

1.1.0

1.1.0.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

  • php >=5.2.0
  • ext-curl *

 

by Tijs Verkoyen

13/10 2012

1.0.6

1.0.6.0 https://github.com/tijsverkoyen/CssToInlineStyles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

  Sources   Download

BSD

The Requires

  • php >=5.2.0
  • ext-curl *

 

by Tijs Verkoyen