What do Flicker, Yahoo, Facebook, and Wikipedia have in common? Like many other sites (including this one), they use PHP. Here I briefly review the history of the humble little scripting language that has become one of the most popular Web technologies in the world.
Okay, who’s this fellow?
Meet Rasmus Lerdorf, a software engineer from Greenland. In 1994, he began writing a collection of programs he called “Personal Home Page Tools” or PHP Tools. A year later, he released the software, version 1.0, under a Free license. It was good timing, with the popularity of the Web exploding and behind-the-times CEOs circulating panicked memos to their subordinates, warning them to gear up or face obsolescence.
PHP Tools 1.0 looked nothing like what you’ll see in the PHP 7.x line, of course; Lerdorf’s initial effort shared the same motive as many other Free and Open Source projects: succinctly, “scratch your own itch.” FOSS (Free and Open Source Software) carries an instinct from the early days of computing, which in turn inherited it from the scientific and academic traditions. That is to share what you’ve discovered or invented. And by the release of PHP/FI 2 in late 1997, PHP had its own developer community and was rapidly transforming from a set of lightweight home page tools to a Web application programming language.
The success of a project shows in numbers, and PHP is among the most successful. Popping onto the burgeoning Web scene less than a month after the initial release of Java, and far less ambitious in its initial release, its mass appeal is obvious in retrospect. By 2003, with its own syntax and a broad array of core functions, PHP ran on servers for an estimated one-third of all Web domains. While early implementations weren’t necessarily easy for non-experts to install, it offered a gentler learning curve (and lower cost) than Java. Probably part of its ease is explained by Lerdorf’s own sentiment: “I really don’t like programming. I built this tool to program less so that I could just reuse code.”
Using an acronym instead of an explicit name is great when your project scope changes, as the community learned in 1997. That was when Andi Gutmans and Zeev Suraski opened collaboration with Lerdorf and undertook a complete rewrite of the parser. Their rebuild started major version 3, the first version that resembles what’s commonly in use today. “Personal Home Page Tools” became “PHP: Hypertext Preprocessor”, a recursive acronym (if you’re not used to the humor of the FOSS communities, you may not have encountered many of these yet, but they come up: GNU stands for “Gnu’s Not Unix”; LAME expands to “LAME Ain’t an Mp3 Encoder”; etc.) Gutmans and Suraski later founded Zend Technologies, a major maintainer of PHP ever since.
Starting with version 3.0, PHP began to offer easy extensibility in addition to a mature core and a considerable feature set. Application developers could leverage multiple data stores, APIs, and protocols, and anyone with adequate general programming ability could write additional extensions. Gutmans and Suraski continued to make major contributions. The Zend engine, their rewrite of the PHP core, marked the 4.0 release. Version 4.0 came as an answer to the demands of increasing application complexity, which strained the functional limits of the 3.0 core. The new version offered greater modularity and performance in complex apps, session support, security improvements, and other features critical to more sophisticated projects.
Zend engine 2.0 became the core for version 5.0 and beyond in July 2004. By this time PHP had many supporting projects, online extension repositories, an extensive documentation base, and an application base comprising perhaps hundreds of millions of computers around the globe. A year later, a project was underway to introduce Unicode to PHP. Since this would require extensive internal changes, the release was proposed as major version 6.0. For reasons that warrant their own article, and one I haven’t written, version 6 never saw the light of day. There were books printed and published in anticipation of its release, and I nearly bought one instead of the three-inch thick chopping block of a reference book that I used as my desk reference while struggling to graduate from video games to productive work. (Pro tip: don’t buy a book about a thoroughly document Web technology with an open, international community devoted to its maintenance and use. Just use search and RTFM; the trees will thank you.)
Ultimately, PHP 6 was vaporware and its unicode features became part of PHP 5.3, which still runs some servers right now. Not many, I’d hope, as that branch isn’t maintained anymore. When I check right now (as in this instant), php.net shortcuts downloads of 5.6.35 and one each of 7.0.x, 7.1.x, and 7.2.x releases. Which brings us up to the current version, namely the 7.x series, which is the subject of the article series I’m introducing now. Released in late 2015, PHP 7.0 marked a major improvement in performance over immediate predecessors, as well as quite a set of new features and functions. All of this is good news for application developers relying on PHP to deliver modern applications on a modern scale; the bad news is that, as with many language updates, some features are deprecated, and you can’t do everything the way you used to. I’m planning on covering all of that in a comprehensible way, so if you’re reading this before there’s anything else to follow, stay tuned.
- 1280px-Rasmus_Lerdorf_August_2014_(cropped): Rasmus Lerdorf and friends
- php-logo: PNGImg