You are here

public function Twig_Environment::display in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/twig/twig/lib/Twig/Environment.php \Twig_Environment::display()

Displays a template.

Parameters

string $name The template name:

array $context An array of parameters to pass to the template:

Throws

Twig_Error_Loader When the template cannot be found

Twig_Error_Syntax When an error occurred during compilation

Twig_Error_Runtime When an error occurred during rendering

File

vendor/twig/twig/lib/Twig/Environment.php, line 360

Class

Twig_Environment
Stores the Twig configuration.

Code

public function display($name, array $context = array()) {
  $this
    ->loadTemplate($name)
    ->display($context);
}