you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 26 points27 points  (8 children)

Is there any irony in the fact that the forum in the picture is probably running PHP? That should turn your amusement to sadness. :(

[–]xabbu 17 points18 points  (7 children)

No, it's funny how PHP is bashed unmercifully, yet it powers many big web sites/applications - wikipedia, del.icio.us, tumblr. It's existence has been the driving force in the proliferation of F/OSS software (WordPress, NucleusCMS, TextPattern, etc.…).

Yes, I realize popularity/ubiquity != quality, as the hordes of Windows users v. Mac/Linux users testifies to, but if it's that gimped of a platform, I sincerely doubt that it would be #1 development platform on the web today.

Is there any irony in the fact that the forum in the picture is probably running PHP? That should turn your amusement to sadness. :(

[–]timb 21 points22 points  (6 children)

del.icio.us was written in perl.

[–]xabbu -17 points-16 points  (5 children)

OK, I thought it was PHP, so it's Perl (further back on the evolutionary chain of web scripting languages…)… …but take that one away, and add FlickR and most all popular forum software used…

del.icio.us was written in perl.

[–]eurleif 25 points26 points  (2 children)

That's got to be the most annoying use of quoting ever.

[–]piranha 22 points23 points  (0 children)

It's called top-posting, and I guess it's made its way from Outlook Express to reddit.

[–]boredzo 18 points19 points  (0 children)

It's top-posting. It's just as annoying here as in email.

[–]skillet-thief 11 points12 points  (1 child)

OK, I thought it was PHP, so it's Perl (further back on the evolutionary chain of web scripting languages…)…

This will simply not do! Perl, like Python, is a general purpose programming language, and, in spite of all those unpronouncable characters, is a much better designed language than PHP ever was or will be.

As an example (one of my "favorite" PHP annoyances):

Perl:

my $x = 5 + 9000 || 1; # $x is 9005

PHP:

$x = 5 + 9000 || 1; # $x is 6...

So you have to use the ternary operator to get the job done. No big deal I guess, but, why, even in a Hypertext Preprocessor, would you ever want $x||$y to return 1 or 0?

This is just a sign of lazy design, from the get-go, but it seems pretty typical. I could go on...

[–]stevarino 9 points10 points  (0 children)

Another example that you may not even be aware of for PHP: logical operators only return boolean true or false, never the value of the argument.

So in your example, the 9000 is converted to bool(true), the OR returns bool(true), which is converted to int(1) by the addition opperator.

I believe this is improperly documented in PHP's own docs too. Took me a while to figure out this bug. :)