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 trialismail houssaini
Courses Plus Student 240 PointsInside of the body tags add a php statement that echos the phrase "Hello World"
that was the question and my answer was as follows <p><?php "Hello, World;" ?></P> however it didn't let me go through to the next section
<html>
<head>
<title>PHP Basic Usage Challenge</title>
</head>
<body>
<p><?php echo "Hello, World;" ?></p>
</body>
</html>
6 Answers
Erik McClintock
45,783 PointsIsmail,
These code challenges are very particular about what they accept, and you have to make sure you do things EXACTLY as they specify. In this case, you have two errors:
1) Your semi-colon is inside your quotation marks, making it a part of the string that you're echoing, and thus leaving the statement unclosed. You need to move the semi-colon outside of the quotation marks.
2) You are echoing "Hello, World" with a comma. You need to echo simply "Hello World"
Erik
Hugo Paz
15,622 PointsHi Ismail,
You have the semi colon inside the string, it should look like:
<p><?php echo "Hello, World"; ?></p>
PHP requires instructions to be terminated with a semicolon at the end of each statement.
ismail houssaini
Courses Plus Student 240 PointsThanks guys!
Samantha Nyamushamba
13,060 Pointsim also facing same challange
MUZ141022 Kudzai Yesaya
4,071 PointsInside of the body tags add a php statement that echos the phrase "Hello World"
Sean Flanagan
33,235 Points<p><?php echo "Hello World" ?></p>