What Installer really should have said was:
That's incorrect. If you run your code, you see that it gives you:
0
2
Basically, the way to think of it is this:
When you call $i++, it will give return the value and then increment. ++$i on the other hand will increment the value first, and then return the value.
Understand? $i++ and ++$i by themselves, on their own line, you won't notice a difference. Within the same line, or worked with within the same time line of events, and you will notice. Like so:
<?php
$i=0;
echo 'This will step through each step and echo out $i along the way:<br><br>';
echo 'Our original value of $i: '.$i.'<br>';
echo 'With $i++ we get this : '.$i++.'<br>';
echo 'Now, the value of $i is : '.$i.'<br>';
echo 'So with ++$i we now get : '.++$i.'<br>';
echo 'And our final value of $i is: '.$i;
?>
That will output:
This will step through each step and echo out $i along the way:
Our original value of $i: 0
With $i++ we get this : 0
Now, the value of $i is : 1
So with ++$i we now get : 2
And our final value of $i is: 2
Does that help at all?