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
Mihir Mittal
3,147 PointsJavascript vs Php
What is the basic difference between Javascript vs Php? Which of them is required to build an interactive website ?
2 Answers
Julie Myers
7,627 PointsTo build interactivity into your website you will need JavaScript and know how to get around the DOM (document object model) via the DOM API.
PHP is typically used for backend stuff. There is still a lot of PHP coding around, but personally I'm not bothering to learn PHP since it is slowly getting replaced by node.js. There are plenty of jobs where PHP is not used at all.
Other then that JavaScript and PHP are two totally different languages. Their syntax can be very different along with many other things that are different. To put it another way learning JavaScript inside out will NOT teach you how the finer details of how PHP works, and visa-versa.
Julie Myers
7,627 PointsHi Steve,
Thanks. How do I re-post it as an answer?
Julie
Steven Parker
243,318 PointsSteven Parker
243,318 PointsGood answer, Julie, you might want to re-post it as an actual answer.
And regarding your node.js prediction: I'm already a JavaScript user, I was planning on taking the PHP course but now I'll have to give it some more thought!