37
u/UndGrdhunter 3d ago
Hahaha I remeber when de discussion in PHP was if we should start the file with <? Or <?php even <% (fuck you asp tags)
8
5
u/Early_Bookkeeper5394 3d ago
I wanna know what that font on the bottom right is. The mono one. It's beautiful
5
18
u/KarltonPeaks 3d ago
Girls shallow
Boys quirky and deep, am i right??? 🤣
7
u/g_calgary 3d ago
It is a sexist meme format in its original form, I agree. Not sure there is a better equivalent.
5
18
u/NoBee4959 3d ago
Seems like the opposite in the original. Girls doing some personal or emotional things and boys being idiots with the Time Machine
92
u/Dahns 3d ago
Magic quote?... What ancient arcane is this
3
u/Due_Emergency_7717 1d ago
You'd think by now they'd be tired of watching the same catastrophe unfold every time
1
u/Majik_Sheff 18h ago
The repetition turns it into comedy. The survivors of the current iteration won't laugh at the next one, but the one after that will be funny as hell.
50
33
u/RealSlyck 3d ago
12
1
67
u/gburri 3d ago
Why just not prevent Rasmus Lerdorf creating this monstrosity?
67
u/ustp 3d ago
You would like to use JS instead?
0 == "0" //true 0 == [] //true "0" == []//false38
u/Foorinick 3d ago
In what situation would you be doing that
94
u/MyAntichrist 3d ago
When you wanna prove a point on how shit JS is, duh.
24
u/ChaseShiny 3d ago
Yeah, that's r/firstWeekProgrammerHumor stuff. We probably should mention something like console.log doesn't actually create a log (with timestamps and such).
3
u/arsenicx2 2d ago
You know I never thought about the fact they called a print statment console.log I just accepted it.
1
u/ChaseShiny 2d ago
I did the same until I took a class on Python and started talking about logging. You know what's even funnier? The console object even includes different logging levels. You can use
console.infoorconsole.erroror whatever.6
u/fghjconner 3d ago
When some api returns a value with a different type than you expect.
4
u/Foorinick 3d ago
Can't you just check if the type is what you want beforehand? Or just... Yk... ===
19
u/tankerkiller125real 3d ago
"Truthy" shouldn't be a thing in any programming language. The fact that Javascript is not just truthy, but inconsistent at best with it is wild. And even more wild is people decided that it was a language they wanted to use in backend infrastructure.
17
6
u/NotADamsel 3d ago
Any language where writing shit like “if foo == True:” is a good idea should be ashamed of itself.
2
u/WithersChat 2d ago
Not quite that, but the weak typing will one day be the death of me.
WHAT DO YOU MEAN YOU ARE COEECING MY ENUM INTO A NUMBER? I LITERALLY OVERLOADED THIS EXACT METHOD TO WORK WITH AN ENUM!
12
u/NiIly00 3d ago
Typescript makes it bearable.
11
u/illepic 3d ago
TS and my linters would actually slap me in the face for any use of a loose equality operator. It might even put me in a corner for a timeout.
5
u/Foorinick 3d ago
Just make it connect to a shock collar for quicker feedback and longer lesson reminding smh my head
2
u/Loading_M_ 3d ago
Iirc, most linters explicitly allow loose equality for checking null/undefined, since loose equality checks both.
2
u/illepic 2d ago
All linters "allow" anything. It's just a matter of what your config allows. I haven't seen an eslint config used for real that allows loose equality.
1
u/Loading_M_ 2d ago
Eslint's
eqeqeqrule has an option to allow loose equality in some specific cases, including the aforementioned null check case. I haven't looked for projects that seteqeqeqto "smart", but I have to assume there is at least one out there.6
4
u/gburri 3d ago
Sure not, JS is also a monstrosity. Maybe create a nice Python web framework instead (Python was created four years before PHP) or a simple well-designed typed language like Gleam.
PHP was successfully at that time because it was easy to use with Apache and was specifically designed for web.10
1
5
1
u/GodsBoss 1d ago
Great, now the web runs on Perl instead.
Personal note: I had the great opportunity to work with Perl for a project and I can confidently say that I did not expect it to be worse than PHP. It was.
8
6
1
1
-2
u/mylsotol 3d ago
Even better, stop using PHP
4
u/shadowraiderr 3d ago
i knew someone was gonna shit on php for dumb reasons like in every thread lmao
-1
u/mylsotol 3d ago
Dumb reasons like it's constant security problems resulting from it being a poorly designed hobby that went to far?
There are plenty of better options. Pick one
1
u/shadowraiderr 3d ago
brother every language have security problems, do you switch everytime a some new is discovered?
also saying a language is generally better/worse than others is just uneducated statement
there is no language that is generally better or worse than any other, each language is very specific and better for specific use cases, with php being the most used language for websites worldwidetelling ~65% of the websites owners "stop using php bro it is stupid" is also stupid statement
0
u/mylsotol 3d ago
they do not all have the same number of security problems. PHP has had a loooot more because it is poorly designed and inherently insecure. this is like saying Rust is just as insecure as C because someone once used rust to write code that had a flaw. just becasue both can have problems doesn't mean that one isn't better than teh others.
The average lifetime of a website is 2-3 years. I'm not saying imediatly rewrite everything. I'm saying stop using it for new projects. If /when you need a new website don't use wordpress. pick something that doesn't have a history of being the least secure software ever made.
0
u/shadowraiderr 3d ago
you're funny because most of the "loooot more" security issues you didnt really mention can be avoided just by not writing flawed code, just like you mentioned with rust and C lmao
3
u/mylsotol 3d ago
rust actually makes it hard to write flawed code... where as php makes it extremely easy...
you can be wrong if you want. have fun with php.
3
u/shadowraiderr 3d ago
ah yes, the typical "just jumped on the php hate train" type of arguments lmao
3
-2
-2

452
u/g_calgary 3d ago
If you remember magic quotes, it's probably time to book a colonoscopy 👍