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 trial

PHP PHP Basics Daily Exercise Program String Manipulation

Oli Collins
Oli Collins
2,385 Points

Question on task 3 is unclear. Clear as complete mud.

States to add an escape character, but multiple attempts which are technically correct are displayed as incorrect.

index.php
<?php

//Place your code below this comment

?>

Can you show the code you tried for part 3? The one above is the starting point of the challenge.

1 Answer

Filipe Pacheco
seal-mask
.a{fill-rule:evenodd;}techdegree
Filipe Pacheco
Full Stack JavaScript Techdegree Student 21,416 Points

Hi Oli,

You have to add the escape character to break a new line. you use the \n for that, right after the line given, with no space. Try this code below.

//Place your code below this comment
$firstName = 'Rasmus';
$lastName = 'Lerdorf';
$fullname = "$firstName $lastName";
echo "$fullname was the original creator of PHP\n";