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 trialDaniel Harrison
2,944 PointsSyntax Error
with this code
16 if (!isset($item)) { 17 header("location:catalog.php"); 18 exit; }
getting this error Parse error: syntax error, unexpected 'location' (T_STRING), expecting ']' in /home/treehouse/workspace/details.php on line 17
2 Answers
Samy Basset
11,862 PointsHey Daniel, maybe a stupid question but you're sure that you dont have the line numbers between your code right? The 16, 17, 18 part. When I copy your exact code everything works fine.
Samy Basset
11,862 PointsNo problem man!
Daniel Harrison
2,944 PointsDaniel Harrison
2,944 PointsYou were right Sammy. The problem was in a previous code line. Thanks