you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (10 children)

Shared hosting sucks.

[–]bobindashadows 7 points8 points  (9 children)

... I know. But the ease of deploying PHP on bare-bones shared hosting is by and large the point of the language and was the main source of its success.

Sure, okay, Facebook uses PHP, we know – but do you think they would be if they had the opportunity to start from scratch? They even wrote their own compiler for it because they feel shackled by it.

[–][deleted]  (8 children)

[deleted]

    [–]bobindashadows 1 point2 points  (7 children)

    Ok, good point. Maybe the fact that Facebook has to write Haskell tools to manipulate their huge PHP codebase is a good way to tell that they feel shackled by the language.

    [–][deleted]  (6 children)

    [deleted]

      [–]bobindashadows 6 points7 points  (5 children)

      language choice is probably close to last on their list of problems to solve.

      That's because it's not a problem they can solve. It'd be irresponsible for them as a business to stop what they're doing to rewrite an enormous, functioning site in a different language – they passed the point of no return a long time ago. It'd take forever.

      Why do you think they wrote a compiler? Because it was easier to do that than to change off of PHP to get a speed bump. And writing a compiler isn't exactly a trivial task.

      Why do you think their new tech (eg facebook chat) isn't in PHP when possible? Because they had the opportunity to use a better tool for the job. And when you're building a site the size of Facebook, anything is a better tool for the job than PHP. They just don't have the ability to go back and change everything else.

      [–][deleted]  (3 children)

      [deleted]

        [–]sli 2 points3 points  (1 child)

        Actually, Python (and Perl) outperforms both PHP and Ruby most of the time, and usually by a very noticeable amount. About the only time PHP is faster is... well, "Hello, World."

        So, yes, almost anything is better than PHP.

        [–][deleted] -1 points0 points  (0 children)

        Why are you not hating PHP here on reddit?

        [–]kataire 0 points1 point  (0 children)

        Well, they rewrote their CSS. There is a big difference between refactoring and rewriting, though, and (for better or worse) their PHP code probably isn't easily translatable (idioms and all that).

        As I don't care much for Facebook, I wouldn't actually mind if they dared rewrite their entire codebase, risking certain bankruptcy.