Str repeat

str_repeat — Repeats the given value n times.

Basic Usage:
{"hi"|str_repeat}
Parameters:
Parameter Type Required Description
1 int No number of repetitions (Default 2)

Where the template is:

{$myVars|str_repeat} # renders: as per abc variable value
{"hi"|str_repeat} # renders: hihi
{"hi"|str_repeat:5} # renders: hihihihihi
Was this article helpful?