Live data from Hacker News

PHP Sucks

evertpot.com

121–130 of 297 posts

Re: PHP Sucks

#121
post #85

I started freelancing in my area doing Ruby on Rails, and found it far harder to maintain a project. I also found it harder to acquire clients in my area for new RoR development. More work was available locally with PHP. Clients were more willing to pay. I've done a ton of things in WordPress that shouldn't have been, "to save money". And I've done greenfield development with CodeIgniter, Laravel (v3 and v5), and a c…

I graduated in 2003. I haven't been able to stop coding php. Why? Because of the amount of work. I know other languages, but the pay for php these days is totally astronomical. (I live in sf, pacific-heights / WELLL over 6 figs / wife doesn't work). Currently I feel like I have a massive technical advantage (I wont share). Right now I work on iphone/android backends - at massive scale, top 10 (PHP is fast). When people say PHP sucks, I actually encourage them. We can't even employ a new graduate these days because they are pre-programmed to like node.js (cool! let's rewrite everything!) and to hate php. So yeah! PHP SUCKS!!!

Re: PHP Sucks

#122
There are a huge number of ways to do something in PHP and most of them are terrible. Anyone can figure out how to do anything you would want to do in PHP. Good PHP developers (yes they exist) will know what NOT to do.

The nice thing about PHP is you can pick it up, write an app that does specifically what you need and someone else could maintain it relatively easily.

Most of the large code packages written in PHP are cumbersome, however. PEAR packages are written by some of the rudest, obnoxious, and anti-Zen people on Earth. Not to demonize them too much but I have had several encounters with PEAR people and they all went something like a Game of Thrones wedding.

Re: PHP Sucks

#123
While RoR, Python, NodeJS et al don't solve the most annoying issue for every developer: Deployment. Then they don't solve anything.

And don't start talking about docker... that's a patch/hack to a serious problem, if i need an entire "jail manager" just to run your app then deployment is not as easy as you kins think it is.

Re: PHP Sucks

#124

The thing that hurts PHP the most is lack of structure and patterns used in the most popular projects. These popular projects are usually where the bulk of work lies, where developers point to when they're considering PHP. When juniors start they're typically working on WordPress or Drupal. The problem is that WordPress and Drupal are terrible guides of how to write a web app and that knowledge is completely useless…

I used to like Laravel, but lately it feels so enterprisy. There is a lot of boilerplate in Laravel today and it was changing too fast for me to keep up with it.

If I were to build enterprise software in PHP, I'd use Zend Framework. Not sure why it's not as popular.

Re: PHP Sucks

#125

The thing that hurts PHP the most is lack of structure and patterns used in the most popular projects. These popular projects are usually where the bulk of work lies, where developers point to when they're considering PHP. When juniors start they're typically working on WordPress or Drupal. The problem is that WordPress and Drupal are terrible guides of how to write a web app and that knowledge is completely useless…

I used to like Laravel, but lately it feels so enterprisy. There is a lot of boilerplate in Laravel today and it was changing too fast for me to keep up with it.

If I were to build enterprise software in PHP, I'd use Zend Framework. Not sure why it's not as popular.

Re: PHP Sucks

#126

Earlier quoted context omitted.

Unfortunately, the issues aren't with "new" PHP, it's with the mountains of "old" PHP code that invariably finds its way into your project. Also, having had to maintain a Wordpress site the past few months, may God have mercy on all daily Wordpress devs. I truly admire your stalwartness now in putting up with that.

The problem is that clients really want WP a lot. Bigger and bigger companies currently and for most of their departmental sites. This is WP shoe-horned in a full site CMS function. The thing is, users seem to love it. I would wager that if you just rip out the guts of PHP and leave only the frontend (the /wp-admin part that is), but leave it 100% as it is and write a solid backend in Django/Rails, you have a winner.…

> I would wager that if you just rip out the guts of PHP and leave only the frontend (the /wp-admin part that is), but leave it 100% as it is and write a solid backend in Django/Rails, you have a winner.

I would love for WP to exist as only an admin interface to a clean, backend data store. Unfortunately, the problem is the database schema that WP ships with and the way WP handles data. It's almost impossible to get data out of WP press without using its lackluster DB "abstraction" layer and running the fetched data through its many obscure filtering mechanisms. To top it off, WP smashes everything into a handful of tables and makes doing normal, straightforward relational looks up (as any sane schema would allow for) a complete nightmare. Alas, when you go the WP route, your data is very much dependent on WP (and by default PHP).

Any organization that uses WP for an extended period of time and builds up a non-insignificant amount of data will run into this wall, guaranteed. If you truly value your data and your project is anything beyond a personal blog that you'll give up on in 6 months time, do yourself and your organization a favor and find an alternative solution. If you must use WP, use it as what it was originally intended for: a blog. It's not a framework to develop a complex application off of.

Re: PHP Sucks

#127
post #85

I started freelancing in my area doing Ruby on Rails, and found it far harder to maintain a project. I also found it harder to acquire clients in my area for new RoR development. More work was available locally with PHP. Clients were more willing to pay. I've done a ton of things in WordPress that shouldn't have been, "to save money". And I've done greenfield development with CodeIgniter, Laravel (v3 and v5), and a c…

> More often it's the programmer who sucks, not the language.

Catchphrase so ironic I laugh every time I hear it. The language also is written by a programmer, who sucked in PHP's case IMO.

Re: PHP Sucks

#128
post #27

"There are only two kinds of languages: the ones people complain about and the ones nobody uses" -- Bjarne Stroustrup

They laughed at Einstein, but they also laughed at Bozo the Clown. Yes, every popular language has critics, but that doesn't mean they're always wrong.

Bozo's theory of unified whoopie is closer to being proved correct every day! He will be vindicated eventually.

Re: PHP Sucks

#129

Earlier quoted context omitted.

I think every language has somebody complaining about it anyway.

But PHP & C++ get more complaining than the others, at least where I hang out. So good quote by Stroustrup.

And oddly seem to be the languages where tbe most code is written, go figure.

Re: PHP Sucks

#130
post #85

I started freelancing in my area doing Ruby on Rails, and found it far harder to maintain a project. I also found it harder to acquire clients in my area for new RoR development. More work was available locally with PHP. Clients were more willing to pay. I've done a ton of things in WordPress that shouldn't have been, "to save money". And I've done greenfield development with CodeIgniter, Laravel (v3 and v5), and a c…

Give us a break, as a language PHP is a terrible language, and yes I do develop and get paid because of PHP, and I do so for the same exact reason you listed. It pays the bills and does so handsomely too.

I have 20 yrs of programming experience in various languages than I care to count, as much as 20! So I do know my languages. From an academic perspective, PHP blows! But from a practical standpoint, it's a tool. It get's the job done, so long as you know it's quirks, you can avoid them. It's much better now with the OOP support and with PHP7 supporting scalar type and return types declaration. It's going to even make it possible to develop more robust software.

I'm indifferent to hearing about PHP sucking. So people say it as a put down. Perhaps they groovy or scala. I really don't care. It pays and that's all I care about. When I engage in my own personal projects, I never use PHP. PHP's documenation is not bad, but best-in-class? Please! With that said, I agree with your last sentence, in the sense that a good programmer can get more done with a bad language like PHP than a bad programmer can get done with whatever the hell one chooses to consider a good language.

Post reply on HN