a SensioLabs Product

The flexible, fast, and secure
template engine for PHP

Table of Contents

Questions & Feedback


Twig documentation is licensed under the new BSD license.

The Array Extension

The Array extensions provides the following filters:

  • shuffle


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

$twig->addExtension(new Twig_Extensions_Extension_Array());
This website is powered by PHP and Twig. The Twig logo is © 2010-2016 SensioLabs