What is the difference between php and JavaScript? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 5

What is the difference between php and JavaScript?

23rd Aug 2017, 2:25 PM
Udayasankar.T
Udayasankar.T - avatar
4 Answers
+ 10
php used for server-side script or back end js used for client-side script or front end
23rd Aug 2017, 2:29 PM
Amethyst Animion
Amethyst Animion - avatar
+ 6
Yes!!
23rd Aug 2017, 5:12 PM
AL.The.Flame!
AL.The.Flame! - avatar
+ 3
One of the main difference is that PHP is a server side language and Javascript a client side one
23rd Aug 2017, 2:29 PM
DodécylSulfate De Sodium
DodécylSulfate De Sodium - avatar
+ 3
PHP was originally intended to solve the issue of server-side scripting, while JavaScript was intended for the client-side. However, that gap no longer exists, and with something like NodeJS, JavaScript becomes both the client-side language, as well as a very powerful server-side language. If you're debating, I'd go with NodeJS, but I'm a big fan of PHP also, and you can't go wrong with that either.
23rd Aug 2017, 2:32 PM
AgentSmith