2017 © Pedro Peláez
 

library cloudinary-twig-extension

cloudinary twig extension

image

teraone/cloudinary-twig-extension

cloudinary twig extension

  • Tuesday, July 26, 2016
  • by teraone
  • Repository
  • 3 Watchers
  • 1 Stars
  • 2,375 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 4 Versions
  • 2 % Grown

The README.md

Cloudinary extension for TWIG

This package provides the Cloudinary helper functions to twig., (*1)

Installation

composer require teraone/cloudinary-twig-extension

You will need to define your cloudinary configuration first, (*2)

Cloudinary::config_from_url('ENTER YOUR CLOUDINARY URL HERE');

$twig = new Twig_Environment($loader);
$twig->addExtension(new Teraone\Twig\Extension\CloudinaryExtension());

Usage

To display an image in your view simply use this tag, (*3)

{{ cl_image_tag("sample.jpg", {"alt" : "Sample Image" }) }}

To specify a specific image size you can use this tag, (*4)

{{ cl_image_tag("sample.jpg", { "width" : 100, "height" : 150, "crop" : "fill", "html_width" : 50, "html_height" : 75}) }}

You can add all options as described here http://cloudinary.com/documentation/php_image_manipulation, (*5)

Tests

If you want to test this lib please add your cloudinary URL to phpunit.xml.dist, (*6)

The Versions

26/07 2016

dev-master

9999999-dev

cloudinary twig extension

  Sources   Download

MIT

The Requires

 

The Development Requires

18/03 2016

1.0.2

1.0.2.0

cloudinary twig extension

  Sources   Download

MIT

The Requires

 

The Development Requires

18/03 2016

1.0.1

1.0.1.0

cloudinary twig extension

  Sources   Download

MIT

The Requires

 

The Development Requires

25/06 2015

0.2

0.2.0.0

cloudinary twig extension

  Sources   Download

MIT

The Requires

 

The Development Requires