StringLoader::getSource

public StringLoader::getSource($name)

Gets the source code of a template, given its name.

Parameters

string $name The name of the template to load:

Return value

string The template source code

Throws

Twig_Error_Loader When $name is not found

Overrides Twig_LoaderInterface::getSource

File

core/lib/Drupal/Core/Template/Loader/StringLoader.php, line 40

Class

StringLoader
Loads string templates, also known as inline templates.

Namespace

Drupal\Core\Template\Loader

Code

public function getSource($name) {
  return $name;
}
doc_Drupal
2016-10-29 09:45:15
Comments
Leave a Comment

Please login to continue.