News for hackers. Stuff that matters.
Re:I still love PHP and JavaScript by jasonm23 on Wednesday August 03, 2022 @05:07AM (#32329360)
> in the docs comment section.

A classic boiled frog statement.

__It's not undocumented, someone posted a comment about that bug...__

I will quietly place my face in my hands and weep to the memory of php coding I did 20 years ago.

Seems the same nonsensical masochism is still going strong.

Re:I still love PHP and JavaScript by saurik on Wednesday August 03, 2022 @05:31AM (#32329502)
I mean, I am by no means an expert in PHP, and in fact most of my knowledge of it comes from hating on it (or having been thrust into the unfortunate position of being the system administrator for a popular MediaWiki instance), but even in my limited experience with it from a couple lifetimes ago I know that most of the documentation for PHP is crowdsourced in the documentation comments section. That might be depressing, but that isn't what that comment was defending: it does feel likely to be true that there aren't many "unknown unknowns" waiting for you in PHP.
Re:I still love PHP and JavaScript by troyvit on Wednesday August 03, 2022 @09:56AM (#32331702)
To me the comments section is one thing that sets PHP apart from other languages. Need to learn a new function? Go read about it on php.net, then skim the comments for edge cases.

Need to do something new in Node? Sift through a bunch of search engine spam, read a few dissenting answers on stackoverflow that refer to a previous version, eventually find a library that does what you want, written by skullM4ster2004, plug one's nose and install it.

Re:I still love PHP and JavaScript by ehnto on Wednesday August 03, 2022 @09:43AM (#32331560)
This is a very common trope, someone who hasn't touched PHP in decades who still thinks they know anything about the language and ecosystem now.
Re:I still love PHP and JavaScript by sergiosgc on Wednesday August 03, 2022 @06:37AM (#32329916)
> I will quietly place my face in my hands and weep to the memory of php coding I did 20 years ago.

You should revisit the language. PHP7 was a huge leap forward. It's a different language now.

Re:I still love PHP and JavaScript by bearmode on Thursday August 04, 2022 @04:45AM (#32340650)
PHP has changed a lot. You should give it a try and stop thinking of it as the same language with the same flaws it had two decades ago.
Re:I still love PHP and JavaScript by daef on Wednesday August 03, 2022 @05:33AM (#32329519)
When I had to code in php I've written a css-rule for my browser to hide the user contributions to the docs, since they where often misleading if not plainly wrong.

I remember no discernible border between 'official docs stop here' and 'user contributed opinions start here'.

Re:I still love PHP and JavaScript by momentary on Wednesday August 03, 2022 @09:21AM (#32331339)
I can't attest to how it used to be, but now at least they are in a section labeled "User Contributed Notes". The notes can be voted up or down, so hopefully the dross sinks to the bottom.

I do agree with the sentiment though that these unofficial notes should be taken with a grain of salt. In my experience, they have been more help than hindrance.

Re:I still love PHP and JavaScript by artificialLimbs on Wednesday August 03, 2022 @09:20AM (#32331335)
Maybe that's how it was, but it has a clearly defined header that says "User Contributed Notes" now, with up/down vote counts on each comment.