I started off with PHP, but prefer Node over it and just about anything else imo.
The pros of PHP as well as just about any other server-side language over Node is short and sweet; better built-in methods. String methods, object methods, etc.. JS is rapidly catching up here, but if I found myself wanting more for less, I'd probably move over to Python.
Anyways, PHP is fine for most use-cases, but I've come to love Node for a few things:
NPM (there's just about a package for anything)
The .js file IS the server (no need for Apache/Nginx)
TypeScript
Inherently asynchronous (it takes a lot for the server to block requests)
It's generally the default/starter tech for cloud function services (firebase)
Native server-side rendering support for front-end libraries (vue, react)
The combination of the above points are why I struggle to find much of a reason to use PHP or any other server-side languages.
But if the use-case is to simply model and serve content, just about any language will do the job, including PHP.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I started off with PHP, but prefer Node over it and just about anything else imo.
The pros of PHP as well as just about any other server-side language over Node is short and sweet; better built-in methods. String methods, object methods, etc.. JS is rapidly catching up here, but if I found myself wanting more for less, I'd probably move over to Python.
Anyways, PHP is fine for most use-cases, but I've come to love Node for a few things:
The combination of the above points are why I struggle to find much of a reason to use PHP or any other server-side languages.
But if the use-case is to simply model and serve content, just about any language will do the job, including PHP.