mirror of
https://github.com/fenom-template/fenom.git
synced 2023-08-10 21:13:07 +03:00
Add range support. Tag {for} now deprecated
This commit is contained in:
@@ -279,4 +279,15 @@ class Modifier
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string|int $from
|
||||
* @param string|int $to
|
||||
* @param int $step
|
||||
* @return array
|
||||
*/
|
||||
public static function range($from, $to, $step = 1) {
|
||||
$v = range($from, $to, $step);
|
||||
return $v ? $v : array();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user