2017 © Pedro Peláez
 

library twig-qrcode-extension

A Twig extension for embedding inline QR codes in Twig templates

image

priotas/twig-qrcode-extension

A Twig extension for embedding inline QR codes in Twig templates

  • Tuesday, January 30, 2018
  • by madflow
  • Repository
  • 1 Watchers
  • 3 Stars
  • 1,351 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 51 % Grown

The README.md

Build Status, (*1)

Overview

  • A Twig extension for embedding inline QR codes in Twig templates.
  • The standard filter output is a DataURL string of the processed text.
composer require priotas/twig-qrcode-extension

<!DOCTYPE html>
<html>
    <body>

        <img src="{{ 'http://kewl.example.com' | qrcode(size=200) }}" />

    </body>
</html>

use Priotas\Twig\Extension\QrCode; $loader = new \Twig_Loader_Filesystem(__DIR__); $twig = new \Twig_Environment($loader); $twig->addExtension(new QrCode()); echo $twig->render('index.html.twig');

, (*2)

Available filter options

Option Type Default Description
type string png The image type. Available types are png,eps,svg
label string A label for the QR code
size integer 200 The size of the QR code
version integer auto The version of the QR code. Range 1-40
svg string data_uri How a SVG should be rendered. data_uri is a data:svg+xml blob. inline is an inline svg tag

Dependencies

  • https://github.com/endroid/qr-code
  • http://php.net/manual/en/book.image.php
  • http://twig.sensiolabs.org/

The Versions

30/01 2018

dev-master

9999999-dev

A Twig extension for embedding inline QR codes in Twig templates

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

by Florian Reiss

twig qrcode qr-code fun

20/09 2017

v1

1.0.0.0

A Twig extension for embedding inline QR codes in Twig templates

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

by Florian Reiss

twig qrcode qr-code fun