a Sensio Labs Product

The flexible, fast, and secure
template engine for PHP

Table of Contents

Questions & Feedback

License

Twig documentation is licensed under the new BSD license.

The Array Extension

The Array extensions provides the following filters:

  • shuffle

Installation

First, install the Extensions library. Next, add the extension to Twig:

1
$twig->addExtension(new Twig_Extensions_Extension_Array());
This website is powered by PHP and Twig. The Twig logo is © 2010-2012 Sensio Labs