public function Twig_Environment::render in Translation template extractor 7.3
Same name and namespace in other branches
- 6.3 vendor/Twig/Environment.php \Twig_Environment::render()
Renders a template.
Parameters
string $name The template name:
array $context An array of parameters to pass to the template:
Return value
string The rendered 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/ Environment.php, line 345
Class
- Twig_Environment
- Stores the Twig configuration.
Code
public function render($name, array $context = array()) {
return $this
->loadTemplate($name)
->render($context);
}