Hacker News new | ask | show | jobs
by camus2 3387 days ago
> But each dispute has an argument in favor of PHP — it’s easy for beginners. To my mind, this argument isn’t valid anymore, which is exactly what I was trying to say in this article.

It's still is easier AND cheaper to deploy a Hello World in PHP than a Hello World in any other language. You can get a cheap Apache/PHP hosting for $2/month, use SFTP a get a working app in minutes. The default PHP distribution comes with a lot of extensions.

The problem is that PHP doesn't help a beginner graduate from a basic webpage to a secure and robust application without having to download a complex framework and meddle with configuration files. IMHO by the time you are tempted to use Symfony you might switch to Java or ASP.net directly.

If PHP was really beginner oriented, it would actually do everything it could to use the most secure defaults for every feature, like templating, or sessions.

Microsoft attempted to do that with WebPages, which is kinda what PHP should have been if it was really intended for beginners. WebPages mostly use secure defaults. While it doesn't prevent spaghetti code it makes having to rely on a complex framework unnecessary.

1 comments

a C1 or VC1S at scaleway is 3.6€ per month. This gives you total control to install anything (nodejs, ...)
...and now you're a sysadmin, with a whole new world of exciting career opportunities. And if you can also write bash scripts and spell Jenkins, welcome to devops!

The point is that if you're 13 years old, somewhat crafty, and just want to make a website that puts text on dank memes using ImageMagick to impress your friends, PHP and $3/month hosting with a friendly alligator that you can show to your mom to get her to put her CC in without thinking you'll get hauled off by a black helicopter...will get you to done quickly without having to read a foot of O'Reilly books, 20 DigitalOcean tutorials, 57 Wikipedia pages, and 118 StackOverflow answers.

Spaghetti PHP on shared hosting written by copy/pasting comments from the PHP docs and SO is a fantastic gateway drug for teens who end up being great developers. I love it.