The while loop executes a block of code while a condition is true. When the condition is false, the loop ends, and code execution proceeds to the next statement.

See Also

http://www.w3schools.com/php/php_looping.asp