4 ms·
PHP is incredibly easy for any competent programmer to pick up. If you know C/Java you can get into php pretty easily. If you use structured projects, (symfo
by acomjean 6y ago
PHP is incredibly easy for any competent programmer to pick up.
If you know C/Java you can get into php pretty easily.
If you use structured projects, (symfony) in our case its much easier to use and maintain.
We have older Java and Perl and Python to maintain. Its much harder to get those up and running.
The startup I worked at 8 years ago used PHP and got bought. I think the ability to get into it quickly and get something running is underrated frankly.
- 29athrowaway 6y agoPHP was the most competitive when ASP was around. After that, PHP entered a dark age where almost every other language ran circles around it in terms of performance, security, maintainability, tool support... and literally everything. Some of those problems got addressed but by the time that happened PHP's reputation was irreversibly trashed and now nobody wants to know about it. That is the world we live in. People do not want to learn PHP or work in PHP. Do a survey on any higher education institution and verify it yourself. All the features you feel proud about... go take a look at the Java VM, .NET VM or a JS VM like V8... Those VMs are much more powerful than the PHP interpreter will ever be. Even CPython is faster. Plus, as a Java developer you can make more than a PHP developer and there are more types of development you can do. Mobile, backend, desktop. PHP is mostly limited to backend and it is not even the best solution for that.
- ccajas 6y agoIt sounds like a sad story. PHP's specialization is in rendering dynamic web pages. It was its ONLY purpose (ignoring niche projects like GTK bindings, etc). And yet even against general purpose languages/VM's (where using it for backend web is a choice, not its only purpose), PHP could not remain competent in its own class. It's like building a car designed for just one thing, to go very fast on straight roads, then a general-purpose car comes along and somehow beats this car in this category. How did it lose its grip? Did the PHP Group become too complacent being at the top?
- 29athrowaway 6y agoPHP = a programming language + templating engine. Most general purpose languages do not have built in templating and do not have templating in their standard library. As a programming language, many modern languages have a faster and more optimized runtime than PHP. If the Laravel authors ported their framework to Node, Python or Java it would certainly run faster. As a templating language, it has to run on the server. That means you pay for the computing cost of templating not the end user. Unless you do your templating using a JS solution. On top of that, you have to transfer a rendered page from your application server instead of just serving files from CDN at a fraction of the cost. Overall, PHP is the wrong solution for the wrong problem. I used PHP in 2004 and then moved on. The industry at a large also moved on.
- raspasov 6y agoI would not be so sure on performance vs Python: https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/php-python3.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/... I haven't run the tests myself in 2021, but I used to do PHP for many years, and there were significant performance improvements done in PHP which I remember took it way ahead of Python at the time.
- alexhutcheson 6y ago> Even CPython is faster. The benchmarks I’m familiar with[1] show recent PHP releases to be a lot faster than CPython for many tasks. Are there better benchmarks I should be aware of? [1] https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/php-python3.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/...
- 29athrowaway 6y agoIf you consider that you'll be using numpy and similar libraries, then CPython beats PHP for most important CPU bound stuff.
- wyclif 6y agoPeople do not want to learn PHP or work in PHP. The majority of new programmers might not want to, but I consider it a clever strategy for new devs to get their foot in the door with their first real job. There's always a huge amount of open PHP jobs and if more elite devs are passing over those jobs then it means an opportunity for somebody. And some of those people who start with PHP will move on to more modern or better languages after they get their legs. It's a smart path to get on the dev career track, especially if you don't come from a traditional CS or dev background.
- 29athrowaway 6y agoPHP is not bad as a first language but it is rare that a new developer will prefer it.