2Hi.Biz
Trang chủ
|
TWIG
|
Xtscript
|
Templates
|
Xtgem
Functions Xtscript
AiChat.Wap.Sh
str repeat
Lặp lại một chuỗi
[...] = optional ... = your value[var $... = ]call str_repeat $val=…;$multiplier=...
Code ví dụ:
<!--parser:xtscript-->
assign $input = Foobar
assign $output = call str_repeat $val=$input ; $multiplier=5
print input = $input<br />
print output = $output
<!--/parser:xtscript-->
<!--parser:xtscript--> assign $input = Foobar assign $output = call str_repeat $val=$input ; $multiplier=5 print input = $input<br /> print output = $output <!--/parser:xtscript-->
Code đã chạy:
input = Foobar
output = FoobarFoobarFoobarFoobarFoobar