Live data from Hacker News

Why Developers Hate PHP

jesuisundev.com

1–10 of 114 posts

Re: Why Developers Hate PHP

#3
PHP being awful annoys me so much more than javascript being awful.

At least for the latter the use became mostly unintentional. For PHP, the problem is that it came about at just the right time to be picked up by WordPress and Facebook, hence encrusting itself in most of the web we see.

I dislike WordPress the same way I came to dislike Visual Studio or any other monstrosity. It's a slow, massive, lumbering mess but it's also by the most mature tool for the job it does.

There's no reason to pick up PHP for a new project. Except, I guess if you're just doing simple CRUD and PHP is what you know.

Languages don't matter that much for simple CRUD apps and PHP is a sub par, annoying, inconsistent language that will get the job done.

Re: Why Developers Hate PHP

#4

Here to see how many comments don't bother reading the piece and just react to the title.

I didn't, skimmed.

> PHP is the most widely used language in the world for websites.

Being served does not equate to being used to develop new things.

Is there really that many new websites, website features being authored in PHP? Sure there is maintenance work and some popular platforms are written in it. But beyond that? I haven't seen a job posting in long time.

Re: Why Developers Hate PHP

#5
I know it's cool to hate PHP but I can think of other languages (Perl, VB6, Groovy) I dislike more. For a language to be so hated it has to be used a lot, and that's the primary virtue of PHP: it runs damn-near everywhere. Not only web scripting/apps but you can use it for shell scripting, Lambda/Azure Functions... there are even frameworks for creating native mobile applications with PHP. And I wouldn't be surprised if it compiles to JavaScript as well.

Re: Why Developers Hate PHP

#6
I couldn't find a date on this article, but I don't think this line is accurate anymore:

"Facebook, Wikipedia, Yahoo, Flickr, Tumblr all these sites run in PHP and welcome millions of users every month without flinching."

Facebook dropped PHP for their own language called Hack, which I think is based on PHP but with a lot of the things people complain about changed.

Re: Why Developers Hate PHP

#8
post #6

I couldn't find a date on this article, but I don't think this line is accurate anymore: "Facebook, Wikipedia, Yahoo, Flickr, Tumblr all these sites run in PHP and welcome millions of users every month without flinching." Facebook dropped PHP for their own language called Hack, which I think is based on PHP but with a lot of the things people complain about changed.

> but with a lot of the things people complain about changed.

and some of those things have changed in base PHP as well too.

Re: Why Developers Hate PHP

#9
post #4

Here to see how many comments don't bother reading the piece and just react to the title.

I didn't, skimmed. > PHP is the most widely used language in the world for websites. Being served does not equate to being used to develop new things. Is there really that many new websites, website features being authored in PHP? Sure there is maintenance work and some popular platforms are written in it. But beyond that? I haven't seen a job posting in long time.

There are plenty of job postings. They just mostly say stuff like "Laravel" instead of "PHP".

Re: Why Developers Hate PHP

#10
I "hate" my experiences in the aughts debugging other peoples PHP code, which put me off. But I primarily use JS now, and I feel like it's just as hated (but maybe more loved?). But I can't imagine how much people would hate JS if node came out in 2001, could you even?
Post reply on HN