the scapegoat dev

Why I Still Love PHP and Javascript After 20+ years

Over the last twenty years, I have used over a dozen languages professionally, from C to Common Lisp, from Java to Python, from C++ to Typescript.

Yet, I love janky programming languages. In particular, I really enjoy PHP and Javascript.

Here's why.

They are used by people who get shit done.

This makes it easy to find people who:

There is a lot of FUD that has been cargo-culted throughout the years.

PHP8 is not your grandmother's PHP3, ECMAScript 12 is not your grandfather's Javascript.

Their ecosystems haven't stood still either. Tools like CPAN, PECL, npm have put significant evolutionary pressure on other languages. With its daily new paradigms and frameworks, Javascript has been a hotbed of innovation for years.

Their quality is offset by other factors.

These languages are not popular for their elegance, but for other reasons.

These can be:

PHP is a favorite of mine because of its cgi-bin model:

They are fun.

Because basic areas of the language are problematic areas means that programming comes with a sense of experimentation. There is pleasure in finding ways to write elegant code in a language that doesn't prescribe any.

Janky programming languages are great equalizers.

Because they are quite permissive, they allow people of all levels and backgrounds to get started with programming. You can be a complete PHP beginner and get a real website going within days.

Having started by copy-pasting BASIC snippets and later on making my own websites with PHP2 and PHP3, I feel pride in being able to pay back by helping newcomers where they are.

Poo-poo-ing a 12-year-old or a recent BootCamp graduate because they are writing actual code is missing the point.

In fact, because users are builders and learners because they have diverse backgrounds, janky languages tend to have very active and welcome communities.

I never had issues writing good code.

PHP, Javascript, Lua, Perl all provide effective tools:

Good software is:

None of which depend on the language.

Javascript and PHP in particular come with:

In fact, they have better tooling than many a "serious" programming language.

I love legacy codebases.

A legacy codebase means that the product is performing well. It means that I can often make immediate and impactful improvements.

For me, nothing comes close to the pleasure of improving a product with many users.