Break
It is used to exit a loop prematurely. Once break is encountered, the loop terminates and the program resumes execution after the loop.
for ($i = 0; $i < 10; $i++) { if ($i == 3) { break; } echo $i . "<br />"; }
Continue
The continue statement is used to skip the rest of the current loop iteration and proceed to the evaluation of the loop condition for the next iteration.
for ($x=0;$x<16;$x=$x+1){ if($x%2==0){ continue; } echo $x; }