While loop syntax error


I can't finish "While loops in PHP" because of Parse error: syntax error, unexpected ')' on line 9
As for me - I've made a correct code.

Your First PHP while loop!

$loopCond = true;
while($loopCond == true) {
//Echo your message that the loop is running below
echo "

The loop is running.

echo "

And now it's done.



PHP will recognize the truthy value, $loopCond.

while ($loopCond) {
    // code
    $loopCond = false;

Remember to change the value inside the loop or it will run forever.


I tried even a hint, but syntax error is still there.


Once we've seen it, we can't unsee it. My answer condradicts the example, but is no less pertinent. It's as well this course is sunsetting. So many questions arose that should never have.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.