ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
Text.php File Reference

Go to the source code of this file.

Data Structures

class  Twig_Extensions_Extension_Text
 This file is part of Twig. More...
 

Variables

if(function_exists('mb_get_info')) else
 

Variable Documentation

◆ else

if (function_exists( 'mb_get_info')) else
Initial value:
{
function twig_truncate_filter(Twig_Environment $env, $value, $length = 30, $preserve = false, $separator = '...')
{
if (strlen($value) > $length) {
if ($preserve) {
if (false !== ($breakpoint = strpos($value, ' ', $length))) {
$length = $breakpoint;
}
}
return rtrim(substr($value, 0, $length)).$separator;
}
return $value;
}
function twig_wordwrap_filter(Twig_Environment $env, $value, $length = 80, $separator = "\n", $preserve = false)
{
return wordwrap($value, $length, $separator, !$preserve);
}
}
class_alias('Twig_Extensions_Extension_Text', 'Twig\Extensions\TextExtension', false)
$env
Stores the Twig configuration.
Definition: Environment.php:17

Definition at line 77 of file Text.php.