How PHP ruined my life as a software developer

I started building my first website when I was 10. It was plain HTML, simple things, called “Droloweb, the most hilarious website on the web”, and had a Ulimit (now closed) free domain name (paid by pop-up ads, basically). I was verbally spamming my friends about it until my parents decided to take me out for dinner after the first 1000 views. Not visits, not uniques, just plain old views. It took me about 6 months to get there, and two-thirds of these views might have been me refreshing the page. But who cares? This gave me the love of building things online.

So when I reached age 15, I started using PhpBB, a PHP Bulletin Board (Wow, that’s what PhpBB means! And it was version 2.0.6 at the time) because I wanted a forum about computers. No particular idea in mind, and there were hundreds of them already out there (Just in French. Thousands in English). It’s not hard to start a forum, you can now do it in a few clicks. So I did it.

But then what ? What do you do with nothing on a forum, and nobody to read that big void?

You build content.

And content doesn’t show up by asking your friends to post on a forum. Well, quality content at least, because we had a great time posting random things from the 2000′s. So I decided to start a website that would use the user sessions of PhpBB to avoid having two different accounts (one for the site, one for the forum)… So I had to learn PHP. Luckily I had some pretty geeky highschool friends who helped as motivators and sources of content. Since then, the site evolved (here is a version which shows that I did not know anything about “TL;DR”) , finally got renamed to Aidoweb and is now a fully homemade PHP framework that has no trace of PhpBB. Great, right ? Yes, on my resume. Helped me find my current job. But at what expense?

I hate Java. I hate C. I hate C++. I hate ALL compiled languages.

This is what I got for being lazy. PHP makes life easy (No, I am not saying that you should quit your job if you are doing PHP – no offense note), and I stayed lazy while learning it.

Everything just works on the spot. Your variable wasn’t declared? I’m happy with it. Was the wrong type? I’m happy with it (see code snippet below). Your code is completely inefficient and eats tons of memory ? Well, who cares? The site was too small to have a visible impact anyways. Well, until it was not anymore, but at that point the damage was done already, and when I reached graduate school in a computer science major, I did not really understand what I was doing there. I hate everything

So I arrived in my MsCS, having avoided as much as I could all the compiled languages courses in France (I had a french degree in Networking and telecoms, so it was easier to go towards Cisco stuff) and got prepared to take classes called something like “CS 6210 - Advanced Operating Systems”. 

Well, that must be some Linux thingy, right? (I am a systems administrator now, so it sounded sexy). Well it was not: welcome to the world of low-level C, moving pointers around and knowing exactly what’s where in memory. My PHP brain blew up pretty much instantly, asking where the web-stuff was and why I had errors all over the place about undeclared variables or modules not found when the compiler should obviously know what I’m talking about.

/* This is typically what's wrong in PHP. I learned not to care because PHP
 doesn't care, it will do the job. This should blow up in your face saying that you can't 
do math on a text. What would your kids grades look like in 4th grade if he was coding like 
this? */

 <?php echo "I'm your father" + Luke + 2 + $nothingtosee ?>

=> This displays 2. And that's wrong. A text, plus a random "Luke" linked to nothing, plus a 
number, plus an undeclared variable, can somebody tell me how this can add up?
Python yells when this happens. Or even for a simple type mismatch. And most of the other languages do.

I am glad that the faculty was amazing and saved me from drowning, but giving me the love of C was an impossible task. And that’s set for life.

We need good basics to grow: Un-learning is a hard thing

The human brain is lazy and will “cache” what it knows (this must be the sysadmin in me speaking). Basically, once you have learned something, your brain will pull from what you have learned to tackle any problem and if you’ve learned it wrong, you will continue to do it wrong until you make a huge effort to think out of your boundaries and forget what you know.

So I am not saying that PHP should not be the first language one uses to learn how to code, but this has to be done carefully. I am sure PHP evolved a lot since I last touched it seriously (it was still PHP4!), and maybe all that has changed already, but my experience as an autodidact kid was a really good way to put me on the path of computers, but I learned by browsing forums when I had issues, and did not buy any books.

Take your learning process seriously

I have been blaming a lot of things on PHP in this article, but PHP was just the “easiest” way for me to enter the coding world. I should have bought books, taken classes, be serious about it. I was not. So now, I am trying to learn Python the right way (and the hard way), from scratch, like I did not know anything about programming.

You have choices when interviewing for a software developer position. Just be confident in one of them.

You have choices when interviewing for a software developer position. Just be confident in one scripting and one compiled language to be able to adapt to any type of interview.

I ended up interviewing for a web-developer internship at Google, and it was my first interview ever. They called me because my website was getting big and had hundreds of thousands of visitors. I was in Dublin, interviewing in videoconference with an engineer in Paris and one in Jerusalem. That was an amazing experience, but I did not get the job. Why ? Because when I started answering their coding questions in PHP, they stopped me immediately and asked me to choose between C++ and Java. I chose Java. I failed.

 

So if I have one advice on how to learn something: Make sure that you have great teachers and study materials. The outcome will be life changing. I did not know anything about systems administration and networking before starting my degree, and I now have a great job as a systems administrator. Because I learned it the right way.

 

No offense note: PHP is a powerful language when it is well used, and big websites like Facebook started on that or are still using it. Great frameworks like Symfony or CakePHP help a lot too, and I am absolutely in love with WordPress which is PHP-based. If you are a PHP developer, do not throw rotten tomatoes on this blog (it would splash your monitor only). This is my experience, I still feel more like a PHP dev than anything else, but I just want to make sure that everything I learn now is learnt the right way.

About Alban

Alban is a systems administrator at Indeed.com, and enjoys thinking about entrepreneurship and solve technical problems. He has a french website that provides free computer help and has a moderatly large traffic, and decided to start this blog (and also improv) in English now that he is living in Austin, TX after graduating from Georgia Tech in December 2011. Follow @albdum

21. February 2013 by Alban
Categories: Creative difficulties, Technical difficulties | 9 comments

  • http://gravatar.com/sanchokd j

    I started with PHP and now when I try to learn anything else I get lost at the “Hello World” tutorial. I feel like I cant learn anything else. I feel your pain. Glad it worked out for you.

  • Jacky09

    Ironically, you are still using wordpress…

  • http://www.google.es Perdo

    That wasnt php
    it was you

  • http://gravatar.com/geekcasts julien

    you should reconsider learning c, c++ it’s awesome

  • http://www.informatimago.com informatimago

    Try Common Lisp and Scheme. http://cliki.net. http://schemers.org

  • SK

    I’m 23 years old, and have a job many people my age would kill for.

    Buy my passion is the web. At 16, just before enrolling in the army, I buily a successful blog (now defunct) which at its’ peak reached 6 million pageviews a month. I had to close it because of mandatory enrollement in the army. I never learnt coding, since WordPress was pretty much automatic for my blogging needs.

    I always wanted to learn coding. Make stuff and not just use it. Not rely on a freelancer from Romania or an expensive coder 5,000 miles away. At 18, I attempted to learn code, it was very discouraging. I looked at my peers in the coding community, “he’s only 18 and already has 5 years of exprience, why bother?”…I said the same thing a year later when the passion came back itching…and the same at 21.

    Had I sticked to it at age 18, I would have 5 years of exprience today. I have a subscription on TeamTreeHouse. I understand (not profess) HTML and CSS, and just started with PHP – I like it so far.

    Your post depresses me. I fucking hated Javascript from moment one, even BEFORE knowing how PHP really functioned. Maybe it’s because of the difference between the courses on TreeHouse, but I’m pretty sure you’re right – PHP is so expressive in it’s nature, it makes things quite easy.

    Mind you: I have been learning dealing with PHP for less than 2 weeks.

  • http://about.me/patrickcurl Patrick Curl

    started w/ php as well, and currently moving into Ruby/Rails which is a LOT different and I’m learning to do stuff following a more ‘best practices’ approach, and writing tests. Before my coding was basically all spaghetti code, and my method was write, upload, refresh browser, repeat. Learning TDD is a huge benefit w/ developing agile applications. I’m still not sure I’m employable yet, but am also trying to build some small prototype projects whether as potential startups, or just resume builders.

  • Mario Delgado

    I usually stay away from PHP trashing articles (I’m a php dev), but I completely hate the misleading and incorrect title on this one.

    I started learning programming when I was 10 with the C How to Program book, and later switched to PHP because it was more USEFUL for me at the moment, and it still is. I’ve started learning Ruby (and RoR) and node.js, and I love them, but PHP gets the job the done pretty well.

    It is not PHP’s fault that you’re lazy, avoided compiled languages and went after cisco stuff instead.

    • http://www.oneurl.me Alban

      I did not say that PHP was not useful, and that is why most of my websites use it (I am still better at PHP than anything else). When you are a teenager, it is easier to go for the lazy option: I wanted the language to be useful (as you said), and build nice websites as fast as I could. And it did the job well. But if you want to go further in software later in life, it might get tricky. Again, as the footnone says, I am not denigrating PHP as a whole, only as a learning tool. You started with C so you saw a “more structured” way from the start, which I am sure helped quite a bit.