2017 © Pedro Peláez
 

library data-uri

A convenient class for working with Data URIs in PHP.

image

evought/data-uri

A convenient class for working with Data URIs in PHP.

  • Tuesday, February 3, 2015
  • by evought
  • Repository
  • 1 Watchers
  • 1 Stars
  • 470 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 64 % Grown

The README.md

README.md, (*1)

Eric Vought, (*2)

2015-01-25 DataURI PHP library, (*3)

What This Project Is

The DataUri class provides a convenient way to access and construct data URIs, but should not be relied upon for enforcing RFC 2397 standards., (*4)

This class will not:, (*5)

  • Validate the media-type provided/parsed
  • Validate the encoded data provided/parsed

Examples of how to use the class are in FlyingTopHat's blog post, "Using Data URI's in PHP"., (*6)

Source and History

DataURI is a class originally written by FlyTopHat and was used as an example in a 2012 blog post and as a Gist., (*7)

In 2014, I forked the Gist in order to package it as a micro-library for use by Composer as a dependency in other projects. Using a Gist-based micro-library in composer requires creating a custom VCS-based repository in your composer.json. This is clunky but acceptable in an application but becomes difficult if the host project is itself used as a Composer-dependency because the custom repository definition is not (by design) included in the host project. The repository definition and package requirement must be repeated in each enclosing project--- effectively defeating the purpose of automatic dependency management., (*8)

So, in 2015, I forked my fork of DataURI, this time to move it to a full-fledged GitHub repository so that it could be made into an actual composer-managed library in the Packagist repository and the extra machinery needed to turn it into a production component could be added., (*9)

Licensing

All components are under an MIT license. FlyingTopHat added an MIT license to the original GIST on 2 February 2015 to clarify original license., (*10)

The Versions

03/02 2015

dev-master

9999999-dev

A convenient class for working with Data URIs in PHP.

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

The Development Requires

by Lucas

03/02 2015

v1.0

1.0.0.0

A convenient class for working with Data URIs in PHP.

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

The Development Requires

by Lucas