2017 © Pedro Peláez
 

library inky

PHP Implementation of ZURB's Foundation for Email parser (Inky)

image

hampe/inky

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  • Saturday, October 22, 2016
  • by thampe
  • Repository
  • 5 Watchers
  • 36 Stars
  • 240,290 Installations
  • PHP
  • 9 Dependents
  • 1 Suggesters
  • 8 Forks
  • 5 Open issues
  • 5 Versions
  • 13 % Grown

The README.md

This repository is no longer maintained.

Issue reports and pull requests will not be attended., (*1)

Inky

A PHP Implementation of ZURB's Foundation for Email parser (Inky)., (*2)

Installation

You can install this bundle using composer, (*3)

composer require hampe/inky

or add the package to your composer.json file directly., (*4)

Usage and Examples

Basic Usage.

<?php
use Hampe\Inky\Inky;

$gridColumns = 12; //optional, default is 12
$additionalComponentFactories = []; //optional
$inky = new Inky($gridColumns, $additionalComponentFactories);

$inky->releaseTheKraken('html...');

Add Tag-Alias

<?php
use Hampe\Inky\Inky;

$inky = new Inky();
$inky->addAlias('test', 'callout')

$inky->releaseTheKraken('<test>123</test>'); //equal to "<callout>123</callout>"

Add your own component factory

Add your own component factory, to convert custom HTML-Tags., (*5)

<?php

use Hampe\Inky\Component\ComponentFactoryInterface;
use Hampe\Inky\Inky;
use PHPHtmlParser\Dom\HtmlNode;

class TestComponentFactory implements ComponentFactoryInterface
{
    public function getName()
    {
        return 'test' // name of the html tag.
    }

    public function parse(HtmlNode $element, Inky $inkyInstance)
    {
        // ...
    }
}

$inky = new Inky();
$inky->addComponentFactory(new TestComponentFactory());
$inky->releaseTheKraken('<test></test>');

License

See the LICENSE file for license info (it's the MIT license)., (*6)

The Versions

22/10 2016

dev-master

9999999-dev

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  Sources   Download

MIT

The Requires

 

The Development Requires

30/08 2016

1.3.6.2

1.3.6.2

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  Sources   Download

MIT

The Requires

 

The Development Requires

14/08 2016

1.3.6.0

1.3.6.0

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  Sources   Download

MIT

The Requires

 

The Development Requires

23/04 2016

1.3.5.0

1.3.5.0

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  Sources   Download

MIT

The Requires

 

The Development Requires

13/03 2016

1.2.3.0

1.2.3.0

PHP Implementation of ZURB's Foundation for Email parser (Inky)

  Sources   Download

MIT

The Requires

 

The Development Requires