Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
prabhu lingam6,955 Points
php on laptop
how do i run php on my laptop as you told it needs a server.
Grace Kelly33,990 Points
you need to install either XAMPP/MAMP, depending on if you are using a windows/mac laptop. There is a section in this course that explains how to install it: http://teamtreehouse.com/library/build-a-simple-php-application
Hope that helps!!
I use XAMPP on my laptop and I have helped other students who started with MAMP and ended up having to switch to XAMPP because MAMP did not work for them for some reason, so I recommend XAMPP. But many people use MAMP also.
Gianluca Mauro3,236 Points
You can also add the php executable (located in XAMPP/MAMP installation folder) in $PATH variable, and use the terminal for execute your .php scripts without use the browser. It's very usefull for test some little snippets of code or test functions from the SPL. To run scripts in terminal launch this comand: php my_script.php