Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialJustin Hein
14,811 PointsCode Challenge: 2/3 PHP Conditionals
<?php
$name = 'Mike';
if ($name == 'Mike') {};
?>
When I put this in I get "Bummer! I cannot see the 'if' statement!"
Any ideas?
9 Answers
William LaMorie
11,769 PointsAlso, there's another thread on this issue, it seems that the challenge is broken.
MUZ141049 Kudakwashe Sibanda
3,451 PointsThis worked for me
<?php $name = "Mike"; if( $name == true ) { $info = 'Hi, I am Mike!'; echo $info; } ?>
Jon Benson
12,168 PointsJustin,
What was the question? I see the variable and the start of an if function.
William LaMorie
11,769 PointsThe problem he's encountering, that I am as well, is that the exercise tells you to make an if statement testing if $name == 'Mike', however, it doesn't specify what do, and it says 'Bummer! I cannot see the 'if' statement!' when you try to solve it correctly.
Jon Benson
12,168 PointsThere's got to be a bug, I couldn't get it going either.
Jon Benson
12,168 PointsThere's got to be a bug, I couldn't get it going either.
Paul Carter
12,543 PointsYup, getting this too. Am posting here so I can follow this thread...
William LaMorie
11,769 PointsThe final code challenge for the assignment also seems to have an issue with it, I skipped past and encountered a very similar message there.
Paul Carter
12,543 PointsYes, again - me too. Odd. I'm reporting it as a bug and will reply with the answer, whether it's our error or a bug.
Thanks
William LaMorie
11,769 PointsI also reported it hopefully it will get sorted out soon!
William LaMorie
11,769 PointsThey emailed today, said it was fixed, and it is, in fact, fixed, I finished them
Paul Carter
12,543 PointsThanks Will. Nice one.
Justin Hein
14,811 PointsJustin Hein
14,811 PointsThanks, sorry about the double post, Support just told me to post here.