Bastien Labelle.

Menu & Search

Why PHP is (so much) better than Ruby?

June 27, 2011

I attended this weekend my first Ruby conference, Ruby Lugdunum in Lyon. Besides cool talks and the fun of meeting people like Nick, Blake, or Laetitia, my friend Camille & I did a surprise lightning talk about how PHP is better than Ruby. Here are the slides and a more detailed transcript:

  1. A lot of free hosts: it’s easy to find a PHP host, you just have to google “free php host” and you find a ton of free PHP/MySQL hosts
  2. Bigger community: The PHP community is really huge, and it’s really easy to find a PHP developer
  3. Easy to learn: Most people in the IT field have some notions of C. Adding a $ before every variable, forgetting about typed variables, and you’re good to go. It’s even simpler if you’ve done some Perl too.
  4. We know when the line ends thanks to semicolons
  5. Big websites use PHP: Facebook, Flickr, Wikipedia, and I should add Overblog because I used to work there. All these websites use PHP, and it scales pretty well.
  6. Mark Zuckerberg uses PHP: The richest programmer in the world (well, he’s not a real programmer anymore, but he used to be) is a PHP developer, so PHP can actually make you rich!
  7. Typing skills: due to a more “verbose” syntax, PHP improves your typing skills. This way, any PHP developer types faster than any Ruby one. And this is very important, because you chat faster so you spend more time actually working! ;)
  8. Real blog engines & CMS: While PHP has WordPress, Drupal and Joomla (to mention the most famous ones), Ruby/Rails’ most famous products are Mephisto, Radiant and Locomotive. I think we can objectively say is that there’s a clear lack of features/plugins on the Ruby based systems, probably due to the smaller community?
  9. Pear is better than Rubygem: OK, this was just a troll, to make the audience feel hurt and yell “BOOOO” very hard…
  10. … Which leads us to our last slide: PHP dev have sense of humor ;)

Of course, saying that PHP is so much better than Ruby is pure bullshit, and this talk is, as I hope you guessed, a big big sarcasm. Trolling apart, I think this talk is also quite interesting, since somehow it shows some of the weaknesses of Ruby and its ecosystem.

Anyway, I had a lot of fun preparing and doing the actual lightning talk, and I can’t wait to create another funny one with Camille, even if some people don’t seem to understand our offbeat humor ;)

Slides by Camille Roux & Bastien Labelle: Why PHP is (so much) better than Ruby?

Bastien Labelle

Beach Wanderer. Salt & surf lover.

Related article
Saboteur, when Geek meets Chic.

Saboteur, when Geek meets Chic.

“You’re a man. Dress like one.” It’s the awesome baseline…

When bookmarks made sense.

When bookmarks made sense.

I’ve never really been into bookmarks, even if this feature…

The nine hours capsule hotel.

The nine hours capsule hotel in Tokyo is yet another…

17 Discussion to this post

  1. Bastien says:

    @Nicolas: Totally, and we’re sorry that we totally forgot to give credits to this guy because the slide about typing skills was actually his (but we took some time to correct his PHP code :p and we thought it was licenced under WTFPL!)

  2. Stjepano says:

    I would not say that PHP is better language but it is better choice for most projects, no sarcasm involved :)

  3. Rob says:

    Nice one guys, just a side note though. The typing issue, This is not the first time that I see the typing issues come up in PHP vs Ruby arguments.

    There are number of articles out there that clearly show that in PHP it is completely possible to write one arbitrary method to handle getting and setting internal class variables.

    http://onlamp.com/pub/a/php/2005/06/16/overloading.html

    Case 2: Dynamic getter and setter

    Then again we all know how important it is to have a get and set methods for class variables. I mean my god just imagine if you actually had to use public variables and even simplier $obj->var = ” notation or GASP! not having a get and set for some variables Oh the HUMANITY! Would someone please think of the children!

  4. Wang Y. says:

    Your sarcasm is mixed with some very true points. Popularity is not necessarily a sign of quality (although, sometimes it is), but when it comes to language usage, PHP vs. Ruby wins 127:1 (76% vs. 0.6%)
    http://w3techs.com/technologies/overview/programming_language/all

  5. droope says:

    this is bullshit :)

  6. chocolim says:

    One thing i use to say is that PHP is the best worst programing language.

    Ruby is a better programing language, but there is more phpbb plugins for facebook than forums systems in ruby.

    Sorry for my bad english

  7. Mounir L. says:

    Nice blog. Just one side note, PHP is not capable of handling large scale apps like Facebook without some important tuning. Facebook for that matter uses “HipHop” that converts PHP code into C++ and that by itself improves the performance drastically.

  8. Sean says:

    Definitely great post and comments too, especially I like one by Mounir L – it’s very to the point. In general, programmers are the best guys and gals in the world :) because they can develop extremely complex things and at the same time can look at their industry with lots of humor.

  9. sunwukung says:

    @Mounir Sure, PHP isn’t good enough out the box to handle Facebook, but can you imagine if they’d written it in RoR/ActiveRecord
    PHP is sure one unpopular and ugly beast – but in terms of jobs, PHP (currently) blows Ruby/Python out of the water. Go figure.

  10. whiteulver says:

    I don’t think that we can compare PHP and Ruby. PHP is a scripting language and Ruby is a programming language.

    How fast can you develop a “Hello world” example displayed in your browser with Ruby(without ruby on rails)?

  11. danaketh says:

    I’d stick with PHP, because deploying an Ruby/Rails application is hell. And don’t even think about deploying more different apps. One needs library in version X.Y, another in version Y.Z… And the worst part is how slow Rails apps are. Even badly written PHP apps are a lot faster than Ruby.

    On the other hand, development of the PHP itself sucks and sometimes I’m pretty tempted to kick devs to the nuts for what they bring around. Ruby seems to have straight vision where to go and how.

  12. devsmt says:

    I think we should discourage this type of discussion as possible, humor or not.
    to compare screwdrivers and hammers have never done real work, at the end of the day.
    we should shift the focus instead on the positives sides of both worlds, helping people to choose wisely

  13. Dave Smith says:

    What’s really telling is that you Ruby (well, Rails) guys never, ever shut up about PHP. You have this huge chip on your shoulder about it.

    It screams insecurity and low self-esteem. If you genuinely believed you were using the right tech, you wouldn’t spend all your time thinking about other languages, tongue-in-cheek or otherwise.

    Django + Python beat the crap out of both, of course.

  14. Thomas says:

    You can argue about how you like the syntax of PHP all you want; however, today’s common PHP interpreters are terrible and require an incredible amount of caching to even be practical in a large scale production.

  15. Sasha says:

    I am in PHP wolrd last few years, but last half year I am in some project with Ruby~!@#$. I didn’t like it. I like C, an PHP, and I will never again use Ruby. Sintax, slow performances…

  16. […] Bastien Labelle has posted a new (tongue-in-cheek) post to his blog today about a presentation he and a friend of his recently gave at a conference – Why PHP is so Much Better than Ruby. […]

Leave a Reply

Your email address will not be published. Required fields are marked *

Type your search keyword, and press enter to search