Home
XtGem-
Templates-
XtScript-
Translate this page
Unavailable
Microsoft
®
Translator
Check out this page in {0} translated from {1}
translated from
Original:
Translated:
Automatic translation powered by Microsoft® Translator
Start translating
Stop translating
Close
Close and show original page
Select
Main Index
Predefined Functions
Scripts
Xtforum post
Short Url
goto
Loops and jumps in Xtscript use the
goto
@
target
command
[...] = optional ... = your value
@
target
[...
...]
goto @
target
WARNING:
Endless or very large loops will cause xtscript timeouts!
Example code
Show as text
<!--parser:xtscript--> # Simple loop var $num = 1 @loop_start if $num <= 10 print | $num var $num = ($num+1) goto @loop_start endif print <hr /> # Simple jump if $num == 11 goto @next endif print This bit is skipped return nothing @next print \$num=11<hr /> <!--/parser:xtscript-->
Show as text
Example output
Reload
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10
$num=11
Related pages
if
if and
if or
if not or
if not or not
if elseif
Quick index
assign
basic syntax
comments
concatenation
cookies
custom paging
debugging tools
del
delete
get
goto
if
if and
if elseif
if not or
if not or not
if or
includes
js in xtscript
print
return
source
user defined functions
var
xt files
xtfunctions in xtscript
About us
Contact
Forum