There have been quite a few, “hate on PHP” articles being posted lately it seems as though the let’s hate on PHP train rolls around every couple of years and the hate articles come out to play. This recent article got a lot of attention, it was well thought out and well-intentioned somewhat but that one single post spurned a new-found hatred towards one of the webs most popular languages from other bloggers, including this article which was intelligently titled “Why PHP still sucks, even if you like it” written by a more than obvious Ruby fan-boy with a raging hard on for a language that is used by a handful of people.
The reality is PHP does suck in comparison to other languages like Python or Ruby, but does anyone seriously care? I sure as hell don’t. PHP is my bread and butter, I know it basically inside and out, it gets shit done and gets me paid from my employer and freelance clients, I’ve never once heard a client say: “Please build the site in this language, PHP sucks!” all clients care about is a result, all a company or freelancer cares about is getting paid so they have food to eat and a place to sleep. Comparing programming languages to one another is the equivalent of a nerd dick measuring contest, except everyone has a small dick and nobody has the balls to admit it.
The one thing I love about one of the suckiest web languages around is there are next to no issues deploying PHP on any web-server (with exception of the odd outdated version of PHP being used by a host). How many other web languages around can say they can be deployed with next to no effort or issues on almost any web-host without having to install anything?
I’ve never encountered a problem PHP couldn’t solve and although some solutions in PHP might not be as pretty or efficient as other languages, I could care less. The arguments that PHP is an ugly language are half-truths, PHP only produces ugly code if you suck at coding and don’t care how you go about things, it’s easy to keep PHP code clean if you care.
PHP is cheap to host, cheap to find decently priced & skilled programmers and quick to code in if you know what you’re doing and at the end of the day what does your client truly care about; a final product that can be deployed almost anywhere cheaply, can be modified by one of the hundreds of thousands of PHP developers out there or a final product that might cost more to deploy, can only be worked on by someone who will most likely charge more than a PHP developer but the code-base looks cleaner?
Don’t get me started on the misinformed statements about scaling, security and compatibility. PHP is one of the most mature web languages around and while it might not enforce strict coding guidelines and set ways of doing things (like function naming and indentation), there are certainly no issues you’ll come across that are the fault of the PHP language itself that will prevent you from deploying something awesome *cough* Facebook *cough* Wikipedia *cough* a lot of Yahoo! projects *cough* WordPress. People who call PHP a bad language are merely wasting their time stating the obvious, many people who use it (like me) acknowledge that it sucks, the ability to mix HTML and PHP alone makes me vomit inside of my head.
What more proof do you need that people acknowledge PHP sucks, but serves its purpose well other than the fact that the worlds most popular blogging application WordPress is coded in PHP? Have you seen the WordPress code-base, it sucks, it’s a mixture of backwards compatible code, a retarded inception of spaghetti code, procedural code and object oriented code being inconsistently used throughout the application (sometimes both styles in the one file) and has any of that stopped it being the number one blogging platform, no. And you know why that is? because most people don’t care how shitty PHP is.
So, while you all bitch and moan about how bad PHP is, writing blog posts that nobody cares about I’ll be making easy money and stealing your clients. Remember to keep warm, the streets are cold and mean.