Alternative to for($i


#1

Hello,

Is there an alternative in exeouput for the php following function:
for($i=0;$i<$count;$i++){
}

If yes, can you give an example, please ?

Thank-you, and happy new year 2016
Gilbert


#2

Here is a list of the ‘Control Structures’ available in PHP. http://php.net/manual/en/language.control-structures.php Since PHP does have a ‘goto’ function ( http://php.net/manual/en/control-structures.goto.php ) , you could write your own control loop like this:
`<?php
$i = 0;
$end = 5;
loop:
echo $i.’ ';
$i++;
if($i < $end) goto loop;
?>
You’re not saving anything so I don’t know why you would do it.


#3

Thank-you for your suggestion davebaldwin, but it is not about a php function that i am asking for help but about an exeoutput function (or delphi function that works in exeouput to be more precise).


#4

Sure like for Delphi a loop can be created in HEScript language:

var
 i: integer;

begin
 for i := 0 to Count do
 begin
  ....
 end;