Unfortunately the common argument is not always true. To be honest at this point in time I would say PHP is actually the hardest to find hosting for. I'm a long time PHP developer and just recently tried Heroku out -- its like magic.
Best for generating web pages is a meaningless metric, and...
To be honest my main issue with PHP relates to the defense that "PHP is not as bad as people like to say.". I mean, really - its true. PHP5 is significantly better language than the previous versions, and people always over-exaggerate how bad it is. The problem is that PHP is not a good language.
Whenever I develop in Python/Ruby I actually enjoy the 'feel' of the language, and I'm often impressed by the power it has to do really complicated things in simple concise instructions. Most of the time when I'm working with PHP the feeling is very different. I can perform the same operations but generally theres far more cruft, and a couple manual lookups to see why functions behave differently when hashes ("arrays") have numeric indices (I'm looking at you array_merge!)
> PHP is actually the hardest to find hosting for.
What? No. Do you have any proof of this? I have yet to come across a "normal" shared/dedicated hosting service that doesn't support PHP. That is an insane statement.
The reason for that is because your definition of normal hosting is shared. (On a dedicated host you can run both PHP and Ruby; and they're roughly the same in terms of getting set up.)
In terms of actually finding website hosting for an application?
Saying PHP is the hardest was likely an over-exagguration, but the market for Heroku PaaS style hosting is growing massively and its Ruby runs on it very easily.
Its not hard (at all) to find hosting for either, the only reason in my mind PHP is harder is because of how beautifully PaaS works and that its free for small applications (good luck finding a reasonable free php host -- I know they exist but you'll have to dig through a whole lot of crud first)
The HN crowd is biased in favor of dedicated and virtual servers. But a very large number of mom-and-pop web pages and small business sites are still hosted on shared. That's what normal hosting means to a lot of people, and it's a market that developers of popular tools (like Drupal and WordPress) can't ignore.
Hosting isn't a very good metric in the first place. In a time where PaaS is going crazy and IaaS is crazy easy to find from tons of vendors, shared hosting is an out dated model that is only marginally a better option.
If you like Heroku, check out PhpFog.com or Orchestra.io. It's like magic too.
"PHP is not a good language" what is a good language?
To take your example, I do enjoy the feel of PHP, it feels natural to read to me, and after years of using it I rarely have to check the documentation for function behavior (such as array_merge...).
"...after years of using it I rarely have to check the documentation for function behavior (such as array_merge)."
This should not be something that takes years. I rarely have to check the documentation for similar Ruby functions after using it for only a couple months. After using PHP for 8 months straight, all day every day, I still had to look up almost every standard library function call - even if I thought I knew how it worked, I still had to check because the pervasive inconsistencies in the standard library ensured that I could never be confident in my guess.
(This is only the tip of the iceberg for why I don't like PHP and don't recommend people use it, for other reasons see: fatal errors vs. exceptions, the strange implementation of OOP (late static binding? isn't that an oxymoron?), and the numerous failing test cases / bugs that reveal themselves in every new release.)
Cheap, shared hosting used to be the greatest reason for staying withh php for me. But lately, I've been doing stuff that has required vps accounts, like rendering html to pdf or rendering pdf to png or powerpoint to pdf.
I realized I could just as well be using Erlang, as far as shared hosting support is concerned.
Now I'm thinking about switching to Python or Node. Or even Haskell.
That is not proper support for PHP, but they have had it in BETA for a while. Pagoda Box is the closest to Heroku around, it even does a lot of things much better.
" To be honest at this point in time I would say PHP is actually the hardest to find hosting for"
huh? Every VPS and shared hosting provider out there has PHP hosting.
"Whenever I develop in Python/Ruby I actually enjoy the 'feel' of the language,"
I use a language not because of its feel, but about what I can create with it. PHP is by far the easiest, most supported, and has a ton of real-world examples of sites getting millions of hits/day using it successfully.
"I can perform the same operations but generally theres far more cruft, and a couple manual lookups to see why functions behave differently when hashes ("arrays") have numeric indices (I'm looking at you array_merge!)"
I agree with you there. My one main gripe with PHP is inconsistent syntax/usage. However, I dislike frameworks like RoR because it is too high-level. I feel like I don't have enough power to do some customizations and when I do need to do them in something like RoR, I have to add hacks onto it.
Best for generating web pages is a meaningless metric, and...
To be honest my main issue with PHP relates to the defense that "PHP is not as bad as people like to say.". I mean, really - its true. PHP5 is significantly better language than the previous versions, and people always over-exaggerate how bad it is. The problem is that PHP is not a good language.
Whenever I develop in Python/Ruby I actually enjoy the 'feel' of the language, and I'm often impressed by the power it has to do really complicated things in simple concise instructions. Most of the time when I'm working with PHP the feeling is very different. I can perform the same operations but generally theres far more cruft, and a couple manual lookups to see why functions behave differently when hashes ("arrays") have numeric indices (I'm looking at you array_merge!)