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 Unit Converter Integers

Siraj Khan
Siraj Khan
3,451 Points

I have tried to make index.php and numbers.php files in my editor ATOM. I cannot see my results in the console.?

I have tried to make index.php and numbers.php files in my editor ATOM. I cannot see my results in the console of the numbers.php . Infact it gives an error Unexpected identifier. I have dowloaded MAMP. What mistake am I doing.? Can anyone please help

2 Answers

Cliff Jackson
Cliff Jackson
2,887 Points

I use atom to store the code i learn on here to practice on and i have no problems, Make sure you have the MAMP server running and you should be ok. Otherwise it could be a syntax error.

Try some debugging. Comment all your code and just put: echo 'hello'. If that is displayed, then the problem was with the code. If not, then the problem is via connection to Apache.

  1. check if your work is saved.
  2. Check if MAMP is connected to Apache.
  3. check if you are on the right path in your browser, for example, localhost:80/numbers.php