syanaputra / silverstripe-extra-template-syntax
Extra syntax for SilverStripe templating system.
Package info
github.com/syanaputra/silverstripe-extra-template-syntax
pkg:composer/syanaputra/silverstripe-extra-template-syntax
v2.0.0
2026-01-15 13:28 UTC
Requires
- php: ^8.1
- silverstripe/cms: ^5.0
- silverstripe/framework: ^5.0
Requires (Dev)
- phpunit/phpunit: ^10
- silverstripe/upgrader: ^1.0
This package is auto-updated.
Last update: 2026-03-15 13:53:16 UTC
README
This module add extra syntaxes for SilverStripe templating system.
Installation
To install this module, simply run:
composer require syanaputra/silverstripe-extra-template-syntax
Usage
Repeat
Params:
- Total Repeat - How many times it has to repeat
- Starting Number - The starting number
Example:
<% loop $Repeat(3, 5) %>
{$Index}-
<% end_loop %>
Output:
5-6-7-
RepeatUntil
Params:
- Total Repeat - How many times it has to repeat
- Starting Number - The starting number
Example:
<% loop $RepeatUntil(5, 3) %>
{$Index}-
<% end_loop %>
Output:
3-4-5-