PHP 5.4 emerges from the collapse of PHP 6.0

The developers behind PHP 6 have scaled back their plan to migrate their code base to Unicode

With the pending release of PHP version 5.4, due early next year, the creators behind the popular Web scripting language are including the best parts of the now-abandoned PHP 6.0 project.

"I guess you could say [PHP 6] was too ambitious," said Zeev Suraski, one of the principal contributors to PHP as well as the chief technology officer and co-founder of PHP software vendor Zend Technologies.

Last week, the team posted the second release candidate of PHP 5.4. They plan to release the completed version by early 2012.

With PHP 6.0, the development team's goal was to completely rewrite the language using Unicode, rather than ASCII. Unicode is a computer character set that incorporates the alphabets from most of the world's languages. Previous versions of the language rely on ASCII (American Standard Code for Information Interchange), which encodes only the English alphabet.

At first glance, the idea to move to Unicode makes sense for PHP. It is the most widely used server-side scripting language around the world, according to an ongoing survey from Q-Success's W3Techs. Rasmus Lerdorf created PHP in 1995 to help creating dynamic Web pages by providing basic programming concepts to augment the static markup offered by HTML. PHP is an abbreviation of PHP: Hypertext Preprocessor, a recursive algorithm.

Building a Unicode-based PHP, however, developers found their implementation required twice the run-time memory. Perhaps this is not surprising given that many of the characters in Unicode require multiple bytes to render. As a result, the software, though operational, was "significantly slower," Suraski said.

While the use of more memory may not be a big deal for a server running a single Web site, many of PHP's users run large sites requiring multiple servers operating at full capacity. "When you have a popular website, it's all about density: how many requests per second can your server take?" Suraski said. For these users, a greater memory requirement would translate directly into the need to buy more servers.

Because of this excess memory usage, the developers have temporarily halted work on the PHP 6.0 project, focusing their efforts instead on PHP 5.4 instead.

But while PHP 6.0 has been shelved, some of its improvements have been rolled into the next routine upgrade of the language, PHP 5.4.

For instance, the issue that drove the idea behind full Unicode support -- that of natively using more languages -- has been addressed. PHP 5.4 has "inline support" for a number of new languages, including Japanese and some dialects of Chinese, Suraski said. In prior versions of PHP, users that wanted a specific language, such as Japanese, would have to compile a version of PHP with the desired language, which forked these implementations from the standard PHP base. Now the installer only has to change a configuration setting, which would convert the base to Unicode for the desired language. Unicode isn't activated unless specified by the system administrator.

PHP 5.4 also includes a number of other changes that were originally slated for PHP 6.

One new project is called Traits, which will allow a developer to use a specific piece of functionality in multiple parts of an application. "In each class where you wanted to support logging, you could just use the logging Trait," Suraski said. Suraski likened Traits to Java's Multiple Inheritance.

Also, many of the features that have been deprecated from PHP and were set to be removed in version 6.0 are now being removed in 5.4 instead. One example of this is PHP's Safe Mode, a mode of operation designed for running PHP in multisite implementations. Safe Mode has been both notoriously buggy and gave users a "false sense of security," Suraski said.

Around 500 people contribute to PHP, Suraski said. About a dozen people contribute to the core PHP engine, and dozens of others maintain specific extensions, and over 100 people work on the documentation. Several months ago, the PHP maintainers changed the way the approval process of how new features get added, a process that would allow other maintainers to vote on whether new features get added.

Joab Jackson covers enterprise software and general technology breaking news for The IDG News Service. Follow Joab on Twitter at @Joab_Jackson. Joab's e-mail address is Joab_Jackson@idg.com

Join the Good Gear Guide newsletter!

Error: Please check your email address.

Tags Web services developmentLanguages and standardsapplication developmentzendsoftware

Struggling for Christmas presents this year? Check out our Christmas Gift Guide for some top tech suggestions and more.

Keep up with the latest tech news, reviews and previews by subscribing to the Good Gear Guide newsletter.

Joab Jackson

IDG News Service

Most Popular Reviews

Follow Us

Best Deals on GoodGearGuide

Shopping.com

Latest News Articles

Resources

GGG Evaluation Team

Kathy Cassidy

STYLISTIC Q702

First impression on unpacking the Q702 test unit was the solid feel and clean, minimalist styling.

Anthony Grifoni

STYLISTIC Q572

For work use, Microsoft Word and Excel programs pre-installed on the device are adequate for preparing short documents.

Steph Mundell

LIFEBOOK UH574

The Fujitsu LifeBook UH574 allowed for great mobility without being obnoxiously heavy or clunky. Its twelve hours of battery life did not disappoint.

Andrew Mitsi

STYLISTIC Q702

The screen was particularly good. It is bright and visible from most angles, however heat is an issue, particularly around the Windows button on the front, and on the back where the battery housing is located.

Simon Harriott

STYLISTIC Q702

My first impression after unboxing the Q702 is that it is a nice looking unit. Styling is somewhat minimalist but very effective. The tablet part, once detached, has a nice weight, and no buttons or switches are located in awkward or intrusive positions.

Latest Jobs

Shopping.com

Don’t have an account? Sign up here

Don't have an account? Sign up now

Forgot password?