PHP has so many hidden benefits: - it's stateless by design (much easier to scale) - it was "serverless" before Serverless - surprisingly performant - no "unknown unknowns". it's so tried-and-true, there's no surprises - deployment is so simple, just drop a file on a web server. No middleware needed. - No long compile times because there is no compiling needed. EDIT: why the downvotes? If you don't agree, just reply…
First 10 years of my career were heavy PHP. I’m solidly into Ruby and Elixir now, but I completely agree with you on the perks of PHP. People love to hate on it. https://www.brightball.com/articles/no-such-thing-as-real-pr... (Old article with a lot of dead links now, just FYI).
I still love PHP and JavaScript
351–360 of 402 posts
Re: I still love PHP and JavaScript
#352Earlier quoted context omitted.
They do. It's just that everyone seems to have collectively decided that cgi shouldn't be used anymore.
CGI has become "serverless" and it's hyped up to no end. The more things change, the more they stay the same.
Re: I still love PHP and JavaScript
#353PHP has so many hidden benefits: - it's stateless by design (much easier to scale) - it was "serverless" before Serverless - surprisingly performant - no "unknown unknowns". it's so tried-and-true, there's no surprises - deployment is so simple, just drop a file on a web server. No middleware needed. - No long compile times because there is no compiling needed. EDIT: why the downvotes? If you don't agree, just reply…
fun thing I also wanted to add a point about documentation but you did it yourself, life is fun sometimes :)
Re: I still love PHP and JavaScript
#354Earlier quoted context omitted.
That’s just it. I have to code with the PHP docs open like some kind of arcane recipe book.
Maybe it’s the frequency that you use the language? I go maybe 5-10k loc between needing to lookup anything in the docs at all, and 5-10x that where the issue I need guidance on isn’t in the formal doc. Much more frequently I’m looking up something related to the tools and libraries I’m using. The only surprising thing I’ve learned about PHP at the language level in the last 6-10 months is that you can call array_fil…
It's mostly things like parameter order for certain built-ins that aren't intuitive and/or finding built-ins I've never used or heard of because there are so many obscure ones (there are nearly six thousand) that keep me coming back. For example, how do you disable errors in a DOMDocument? It ought to be as easy as DOMDocument->setAttribute("errors", "false"), but no it's a separate function call to libxml_use_internal_errors(true). There are like five other similar function calls for this too. PHP has abstraction leaks and little inconsistencies like this everywhere.
Granted, languages with small standard libraries, like JavaScript, by contrast get an easy cop out to blame the community of various package maintainers here. But at least in that case someone can always just write a better library.
Re: I still love PHP and JavaScript
#355Earlier quoted context omitted.
> PHP was really nice to get into programming and make a spaghetti website Facebook manages quite well with PHP. Maybe it's your fault you didn't learn how to use modern PHP practices which have been well-documented for over a decade now.
>>well-documented Sources?
Re: I still love PHP and JavaScript
#356Earlier quoted context omitted.
Have you tried a more "modern" language recently? By trying I mean using it for more than 6-10 months. I've been one of the PHP "supporters" until I've found Go and Rust. PHP was really nice to get into programming and make a spaghetti website but the language itself and the ecosystem always felt like a hacking project. The killer feature of PHP has always been the hosting ecosystem. A simple FTP upload would do the…
> PHP was really nice to get into programming and make a spaghetti website Facebook manages quite well with PHP. Maybe it's your fault you didn't learn how to use modern PHP practices which have been well-documented for over a decade now.
I didn't say you can't make it work. You can build great stuff using just bash scripts. I'm pretty sure you can have success with any programming language. That doesn't mean it's the "best" way to do it.
>> Maybe it's your fault you didn't learn how to use modern PHP practices which have been well-documented for over a decade now
I doubt it's my fault. I'm not "special". I think PHP is prone to bugs and bad practices both due language design and bad documentation.
Re: I still love PHP and JavaScript
#357> I love legacy codebases. > A legacy codebase means that the product is performing well. It means that I can often make immediate and impactful improvements. Wow. This person must have worked on very different legacy codebases than me. Legacy Javascript code, to me, is something that I do not want to touch with a 10 foot pole, because every little piece of it can be intertwined with and used by many other hidden pla…
They said impactful champagnes, and that the product is performing well. Nothing in your comment contradicts that.
Re: I still love PHP and JavaScript
#358Earlier quoted context omitted.
CGI has become "serverless" and it's hyped up to no end. The more things change, the more they stay the same.
With the crucial difference that "serverless" is proprietary and uses different APIs, so you can't just go to whatever hosting company you want.
Re: I still love PHP and JavaScript
#359Biggest flaw of php to me is getting paid well and the number of jobs. From the stack overflow dev survey, php devs get paid much less than others. Laravel and php is a beast, super easy to use. All that annoying shit is setup for you. But, how many ppl hire Laravel devs? Job boards are stacked with react, vue etc. Personal use is great though.
I'm a PHP dev, I didn't take part in StackOverflow survey and ~15 senior PHP devs that I know personally didn't take part either. Judging on such a small sample, I'd be guessing that it's safe to assume that survey is missing crucial data from people who do get paid well. I'm 22 years in the business, 16 years working at the same place. At this point, there's various bonuses next to salary. After so many years, it's…
I haven't looked recently, are there a lot of remote positions for US employees writing PHP for $200k+ base plus bonuses?
I'm not even talking about the crazy-high comp from FAANG companies here, just Principal developer roles paying more than $200k base, with bonuses as well.
My anecdote and your anecdote combined don't make data, of course, but I know my comp climbed pretty dramatically when I left PHP behind.
Re: I still love PHP and JavaScript
#360I mean, everyone knows tech is moving fast. Especially the JS ecosystem. So now why are you talking sh*t based on your experience like 3 or 5 years ago? At least just go around and read more before you comment.