Why is PHP popular?

Wow... I have really neglected my self-imposed blogging duties lately. I suck.

Anyway, a graduating high school kid asked me via IM why PHP was so popular and why I'm a .NET guy. He wasn't trying to start an argument or anything, he actually was looking for an answer.

I told him that PHP is popular because it's relatively easy to learn. While I don't have any particular data to point to, I think that it's safe to say that the vast majority of sites on the Internet are not maintained by computer science people. These same people are probably not running Match.com either, so a PHP site makes perfect sense because it's easy to learn and serves its purpose.

And why am I a .NET guy? Well, I probably could've been a Java guy too, but since I started in ASP.old, it seemed like a logical progression. Once you really get object-oriented programming, it's hard to do anything else, especially script. In big, distributed applications, it's just the right tool for the task.

Normally discussions like that degenerate into pissing matches, but the availability of PHP has certainly been good for the Internet. I don't know why people can't admit that. It's just not something that would work for the things that I do.

8 Comments

  • PHP also has the advantage that ISPs can make it available with very low costs -- between Linux, PHP and MySQL/Postgres, their cost of making it available in a hosting plan is about $0. Compare this to ASP.NET that requires at least Windows Server 2003.



    However, I agree with you that the Code+Markup crowd feel that PHP is easier to learn and get working. I can't imagine many big systems written with PHP being all that maintainable, though -- although I have been surprised in the past.



    Is it better for the Internet? I guess. It means there are more Web developers out there.

  • I totally disagree about the cost thing. You always need people to maintain this stuff, and as a percentage of costs, licensing is always a minor component.

  • I dunno, how much does it cost to maintain a Linux server (my company's advertising notwithstanding) vs. a Windows Server 2003 box? If I'm an ISP, both get set up, and rarely touched (except for patches, etc.). Sure, licensing is only a small component, but so is leaving old, fully depreciated hardware in action making money off of the many people firing up small vanity sites using PHP.



    Oh, and the fact that schools teach it these days (again because of licensing for right or wrong) tends to have a play as well, IMO.

  • "It's just not something that would work for the things that I do"

    Unless you are developing Desktop apps, I can't think of anything else that PHP can't do for you. Although PHP is getting there on the Desktop area, check PHP-GTK.

    Certainly PHP has changed the internet by making web programming accessible to advanced computer users and programmers alike.

  • PHP is very easy to learn. Unlike .NET, it's cross platform, very easy to install & lots & lots of open source code & samples. I code in C, C++, Java, PHP, VB, VC#, ASP, JavaScript & even used to code in fortran & pascal. My favorite is PHP & JavaScript.

  • thank god (and rasmus) for php! imagine the whole web written in java or .net, imagine youtube written in either! every month would start with buying terabytes of ram and loads of cpus.

  • Is that why Facebook wrote a compiler for PHP? [/me rolls eyes]

  • "PHP is very easy to learn. Unlike .NET, it's cross platform, very easy to install & lots & lots of open source code & samples"
    That's false!.Net is easy, you can work with MONO and so on... this sentence is subjective.

Comments have been disabled for this content.