I am using:
$input = array("1", "2", "3", "4", "5");
Now I want to start by printing the first value from the array (1) and another value for the remaining ones (2,3,4,5). Then next time, the print value will be 2 and further values (3,4,5,1). And so on, until the print value is 5 and the other values will be (1,2,3,4).
I am using a for-loop, but after the value 5, the loop should break…
What to do for this case….
out put should be: 1 the first time, then 2 then 3 then 4 then 5 then again 1 then continue on every refresh
Does this do what you are looking for?
OUTPUT