2017 © Pedro Peláez
 

library php-yaf-twig

Twig extension for Yet Another Framework.

image

suin/php-yaf-twig

Twig extension for Yet Another Framework.

  • Wednesday, August 29, 2012
  • by suin
  • Repository
  • 2 Watchers
  • 9 Stars
  • 130 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 6 Forks
  • 3 Open issues
  • 3 Versions
  • 2 % Grown

The README.md

\Suin\Yaf\Twig

Twig extension for Yet Another Framework., (*1)

Installation

You can install via Composer., (*2)

At first create composer.json file:, (*3)

{
    "require": {
        "suin/php-yaf-twig": ">=1.0"
    }
}

Run composer to install., (*4)

$ composer install

Finally, include vendor/autoload.php at index.php, (*5)

require_once 'vendor/autoload.php';

Add to Bootstrap.php:, (*6)

<?php

use \Suin\Yaf\Twig\Twig;

class Bootstrap extends Yaf_Bootstrap_Abstract
{

    /**
     * @param Yaf_Dispatcher $dispatcher
     */
    protected function _initTwig(Yaf_Dispatcher $dispatcher)
    {
        $config = Yaf_Application::app()->getConfig()
        $dispatcher->setView(new Twig(APP_PATH.'views', $config->twig->toArray()));
    }
}

Add to application.ini:, (*7)

[product]

;app
application.view.ext = twig

;twig
twig.cache = APP_PATH "../cache"

[devel : product]

;twig
twig.debug = true

License

MIT license, (*8)

The Versions

29/08 2012

dev-master

9999999-dev https://github.com/suin/php-yaf-twig

Twig extension for Yet Another Framework.

  Sources   Download

MIT

The Requires

 

twig yaf yet another framework

28/08 2012

1.1

1.1.0.0 https://github.com/suin/php-yaf-twig

Twig extension for Yet Another Framework.

  Sources   Download

MIT

The Requires

 

twig yaf yet another framework

25/08 2012

1.0

1.0.0.0 https://github.com/suin/php-yaf-twig

Twig extension for Yet Another Framework.

  Sources   Download

MIT

The Requires

 

twig yaf yet another framework