Live data from Hacker News

PHP in 2021

stitcher.io

91–100 of 309 posts

Re: PHP in 2021

#91
post #3

As someone who works with Rails and Laravel, one of the huge benefits I find working with PHP/Laravel are the speed and consistency of releases. PHP seems to release versions more frequently, and Laravel tags every week. It means there's much less lead time to work with new features/functionality as it becomes available (when it's stable, rather than running on edge).

I once came back to a Laravel project after just one year of working on other projects and had to go through several upgrade guides just to stay up to date. Most changes were quite trivial (yet annoying to make), like namespace changes and other things that should probably have been weeded out before ever making it into a release... It’s why I prefer Symfony if I absolutely had to work with PHP nowadays.

Re: PHP in 2021

#92

Before you call me a troll, know that I worked with PHP for two+ years maintaining both legacy codebases and writing new code with Laravel. My question is: why would anyone want to start something new with PHP in 2021? Is there anything that it does better than any other language/ecosystem? I feel like the community is full of (but not exclusively composed of—there are some gems like Caleb Porzio who write good stuff…

> My question is: why would anyone want to start something new with PHP in 2021? Same reason as any, familiarity. Not all people, even in software, enjoy learning new stuff. PHP might be the only language they ever learned and it has paid their bills for over a decade. No point in learning anything new unless it's absolutely required. As long as major pieces of software are written in PHP, those people will have a st…

- shared nothing architecture - single threaded code execution context - copy files deploy

I was a PHP developer for over 15 years and those three concepts do more to lower the barrier to entry than any other language I’ve come across, and are constantly underestimated in their power to enable developers to concentrate on the business logic of their program.

Re: PHP in 2021

#93

PHP has been in a pretty good place since 7, IMO. These are some great developments. I would say that Laravel is an extremely high quality framework (on par with and even in some ways better than Rails) that nobody should be ashamed to use. It's unfortunate that the stink of old PHP is so powerful and that salaries are still lagging so far behind.

> I would say that Laravel is an extremely high quality framework (on par with and even in some ways better than Rails) that nobody should be ashamed to use. Never heard of Laravel. Decided to take a look. First thing the intro documentation says to do is install something called 'Docker Desktop'. I'm good, thanks. Why do I need Docker to play around with a web framework?

This feels so un-PHP. One of the reasons PHP won is because it was relatively environmentally neutral.

There was a galaxy of free and cheap PHP software whose deployment process was basically "FTP everything up and plug in database credentials." At most, you might have to confirm you had PHP5+, but basically any random cheap hosting or default-config VPS would work with default or near-default settings.

In contrast, a lot of Rails and Node stuff was much more fragile by comparison-- I can recall trying to deploy other people's RoR applications and it turns into a huge rabbit hole of version matching and dependencies that aren't there out of the box and "OMG you never should have started with $distro."

The Docker mindset feels like a snarky response to "it works on my machine"; rather than actually making things reasonably environment-neutral, just ship your machine with every install!

Re: PHP in 2021

#94

Before you call me a troll, know that I worked with PHP for two+ years maintaining both legacy codebases and writing new code with Laravel. My question is: why would anyone want to start something new with PHP in 2021? Is there anything that it does better than any other language/ecosystem? I feel like the community is full of (but not exclusively composed of—there are some gems like Caleb Porzio who write good stuff…

So, one reason to use PHP instead of Ruby is that you will need 100x fewer servers. When you need 100x fewer servers you might also need 100% fewer devops people.

Re: PHP in 2021

#96

Before you call me a troll, know that I worked with PHP for two+ years maintaining both legacy codebases and writing new code with Laravel. My question is: why would anyone want to start something new with PHP in 2021? Is there anything that it does better than any other language/ecosystem? I feel like the community is full of (but not exclusively composed of—there are some gems like Caleb Porzio who write good stuff…

There are many reasons to use PHP:

- you have already a dev team that are good PHP developers, it is stupid to switch to Python or Ruby , you lose their experience and any chance of reusing existing PHp code you have. The dev team probably knows JS so node might be an option.

- maybe you want to build something super simple, like some third party needs to send you a notification event and you want to record that event with other third party API. You can do this with one PHP file , one a super cheap hosting , with code that is simple and clear.

IMO all the dynamic backed languages are at the same level, so if you are experienced in PHP environment there is not enough compelling reason to erase this advantage to start from scratch with Python, Ruby or node.

Re: PHP in 2021

#97
post #81
post #72

Earlier quoted context omitted.

PHP is often a good business decision because there is no shortage of affordable devs to help manage the code. If you're building a small, low-margin business, it may be the best choice. I hate writing PHP btw.

For lost cost Wordpress stuff sure, but for higher end senior type work I think it's worse than other languages. While this is obviously location dependent, over the last year or so I've had dozens of calls from recruiters asking me to come work on PHP (mostly Symfony and Laravel) applications, and telling me they just can't find competent senior and lead devs.

Yep, resonates with me. At the same time, these jobs pay very little compared to other stacks. Go figure why they can't find people :-)

Re: PHP in 2021

#98

Before you call me a troll, know that I worked with PHP for two+ years maintaining both legacy codebases and writing new code with Laravel. My question is: why would anyone want to start something new with PHP in 2021? Is there anything that it does better than any other language/ecosystem? I feel like the community is full of (but not exclusively composed of—there are some gems like Caleb Porzio who write good stuff…

Most ISP support it, and is the cheapest way to get someone on the web without surprises in running costs.

Re: PHP in 2021

#99

Earlier quoted context omitted.

> My question is: why would anyone want to start something new with PHP in 2021? Same reason as any, familiarity. Not all people, even in software, enjoy learning new stuff. PHP might be the only language they ever learned and it has paid their bills for over a decade. No point in learning anything new unless it's absolutely required. As long as major pieces of software are written in PHP, those people will have a st…

- shared nothing architecture - single threaded code execution context - copy files deploy I was a PHP developer for over 15 years and those three concepts do more to lower the barrier to entry than any other language I’ve come across, and are constantly underestimated in their power to enable developers to concentrate on the business logic of their program.

Indeed, there's nothing like just logging in to a linux box you got access at school or pay $1/mo for and typing 'nano public_html/index.php' - stuff Just Works.

Trying to get a python/ruby framework working in the same env, without root access? Whoooo boy. 20 years in the business and I still refuse to do that crap. FastCGI and the like just never work properly the first time in shared hosting.

You need virtual environments to keep dependencies at bay, debugging is a pain if the web server and fcgi process don't communicate properly. Most likely you won't have access to error.log so good luck figuring out why everything returns HTTP 500.

While you're still figuring out how to get helloworld.py to respond, the dude with PHP is already done.

Re: PHP in 2021

#100

Before you call me a troll, know that I worked with PHP for two+ years maintaining both legacy codebases and writing new code with Laravel. My question is: why would anyone want to start something new with PHP in 2021? Is there anything that it does better than any other language/ecosystem? I feel like the community is full of (but not exclusively composed of—there are some gems like Caleb Porzio who write good stuff…

What if your focus is not on elegance of the code but the product? What if you don't want to spend any time on boilerplate and starter project setup but spend all your time on your idea? What if programming is just the means? What if this is not you: https://twitter.com/cassidoo/status/1216871876192088065

PHP used to be light years ahead in this since it is internet native language. With anything else you have a lot of moving parts that need to be aligned in a specific way to make it work, in PHP the default state is ready to go.

How do you deploy your new code to your LAMP server? You put it in a folder. No need for package managers, no need for any other kind of tooling. You even don't need any frameworks beyond your original product requirements.

If it's local server, you drag and drop the file you just typed in the code using your file manager. If it's a remote server you use your favourite FTP app.

If your idea turns out to be worth its salt you can pay an army of engineers to re-implement it in an elegant way.

Post reply on HN