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 trialMatthew Root
5,392 PointsGithub demo
If I am working on github, how would I demo a .php file to see how it would look in the browser before merging it to master? Usually when working on my own I would demo the changes by sending my .php file to the server and then opening up my page in the browser.
2 Answers
Kevin Korte
28,149 PointsYou would want to have a local environment set up so you can run your site locally, and than you can test it there, before pushing it to github.
Matthew Root
5,392 PointsThanks Kevin!
Matthew Root
5,392 PointsMatthew Root
5,392 PointsWhat do you think is the best environment to use for that? LAMP... WAMP? Do those link to a database also? Thanks!
Kevin Korte
28,149 PointsKevin Korte
28,149 PointsFor php I use xampp or mamp. But most of the time now I'm either working in Rails or Meteor, and both have their own web server built in, so I haven't used either in awhile.
And both Xampp and Mamp will include mysql, so you can launch phpmyadmin from the control panel, and create, view, modifiy your mysql database. You'll need to manually configure the database connection (which isn't too hard) unless you're using something like Wordpress, which will do that for you.