תחביר while
בדיוק כמו עם if..endif, התחביר של while..endwhile השתנה גם כן:
Example#1 מעבר: תחביר while..endwhile ישן
<div dir="ltr">
while ($more_to_come);
...
endwhile;
</div>
Example#2 מעבר: תחביר while..endwhile חדש
<div dir="ltr">
while ($more_to_come):
...
endwhile;
</div>
Warning
אם אתה תשתמש בתחביר while..endwhile הישן ב- PHP 3.0, אתה תקבל לולאה אין-סופית.