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 trialTahsin Ahmed
7,828 PointsI'm doing it right and producing the right output but workspaces thinks I'm not...
Is there a certain way I'm supposed to fix this? I typed: date('F d\, Y');
It formats correctly in the Preview...
<?php
echo 'Today is ';
//Place your code below this comment
echo date('F d\, Y');
?>
2 Answers
Greg Kaleka
39,021 PointsHi Tahsin,
You've just about got it, but you don't need that escape character. Remove the \
and you'll be all set.
Cheers
-Greg
Robert Bennett
11,927 PointsThere is a lot of ways to pick the date in the PHP maunal - here is the code that worked for me... It kept throwing a syntax error because the capital F wasn't touching the parentheses!
<?php echo 'Today is '; //Place your code below this comment echo date('F d, Y'); ?>
Tahsin Ahmed
7,828 PointsTahsin Ahmed
7,828 PointsIt works! Thank you very much