News for hackers. Stuff that matters.

Ask HN: Should i go for PHP or Node.js?

I need to learn a language to manage requests from a website (eg. login forms), and i have decided for either PHP or Node.js. I know PHP is pretty easy to learn and server-sided. But i wonder if learning something more client-sided like Node had any advantages? I don't mind the difficulty in learning, i just want to know the basic differences and maybe your preferences overall.
( 6 comments | 2 points | on HN )
Re:Ask HN: Should i go for PHP or Node.js? by byoung2 on Friday March 07, 2014 @01:28PM (#7361835)
I have worked as a PHP developer for almost 10 years now, and I have built some pretty big websites using it (e.g. rushlimbaugh.com, ultimatecoupons.com) but over the past 2 years I have been developing in node.js. I love node because it offers great performance if you have a lot of concurrent connections and I/O, but not a lot of hardware (e.g. an ajax app, websockets). If you are just building a website with some forms, you could probably do it easier in PHP. There are lots of mature frameworks out there for PHP websites (I used Symfony for ultimatecoupons, and EZ Publish for rushlimbaugh). If you are building a rich internet app, I would go with node.
Re:Ask HN: Should i go for PHP or Node.js? by redxblood on Friday March 07, 2014 @01:33PM (#7361855)
Thanks! I guess i'll go with PHP for this one and Node.js in the future. But can you tell me the difference between them? I mean, being PHP a server-sided language and Node a client sided one.
Re:Ask HN: Should i go for PHP or Node.js? by RussianCow on Friday March 07, 2014 @02:21PM (#7362162)
Node.js is basically just server-side JavaScript. Its main draw is its "asynchronous by default" culture, which means that it's very easy to write concurrent applications in Node. It's more involved that PHP, so as the OP said, PHP is probably better for simple sites with a few forms and Node better for realtime apps.
Re:Ask HN: Should i go for PHP or Node.js? by oliverlord on Friday March 07, 2014 @01:38PM (#7361886)
try PHP first, its easier and fits most of average websites needs. Node.js is more about performance and optimizing big systems.
Re:Ask HN: Should i go for PHP or Node.js? by chc on Friday March 07, 2014 @05:24PM (#7363143)
Eh, I don't know about that. PHP requires slightly less to get running, but I find working in Node easier than working in PHP on the whole. I write a lot of PHP, but it's all stuff that needs to integrate into existing PHP codebases like WordPress.
Re:Ask HN: Should i go for PHP or Node.js? by bennyp101 on Friday March 07, 2014 @01:40PM (#7361893)
node is the server side version of javascript