2017 © Pedro Peláez
 

library php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

image

milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  • Friday, December 16, 2016
  • by milanspv
  • Repository
  • 2 Watchers
  • 0 Stars
  • 350 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 7 Versions
  • 14 % Grown

The README.md

inline-images

A PHP lib to handle image inlining in your (css, img src, etc.), (*1)

Install

composer require milanspv/php-inline-images

Convert an image to an inline string value

<?php

// first way to initialize the object
$inliner = new InlineImages\Converter();
$inliner->setPath('/path/to/img.png');

// second way to initialize the object
$inliner = new InlineImages\Converter('/path/to/img.png');

// convert image
echo '<img src="'.$inliner->convert().'"/>';
//or for css
echo 'background: url('.$inliner->convert().')';

Convert a remote image to inline string value

<?php

$inliner = new InlineImages\Converter('http://path/to/img.png');

echo '<img src="'.$inliner->convert().'"/>';
//or for css
echo 'background: url('.$inliner->convert().')';

Inline SVGs

<?php

$inliner = new InlineImages\Converter('/path/to/img.svg');

echo '<img src="'.$inliner->convert().'"/>';
//or for css
echo 'background: url('.$inliner->convert().')';

The Versions

16/12 2016

dev-master

9999999-dev https://github.com/milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

16/12 2016

dev-develop

dev-develop https://github.com/milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

16/12 2016

0.2.2

0.2.2.0 https://github.com/milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

16/12 2016

0.2.1

0.2.1.0 https://github.com/milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

16/12 2016

0.2.0

0.2.0.0 https://github.com/milanspv/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

16/12 2016

dev-improvements

dev-improvements https://github.com/PuKoren/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src

26/06 2016

0.1.0

0.1.0.0 https://github.com/PuKoren/php-inline-images

A lib to handle image inlining in your (css, img src, etc.)

  Sources   Download

MIT

The Requires

  • php ^5.3.0 || ^7.0

 

css inline image svg base64 src