PHP 5.4 features poll: the results
Some innovations of PHP 5.4 have not stand the test of the crowd: deprecation of magic quotes and other strict mode changes did not receive many votes, as well as the closures new features like the binding of $this.
Even the built-in HTTP server, which is quite handy during development, did not manage to hit the podium.
3rd place: upload progress patch (11%)
The upload progress feature is not cited in many places as groundbreaking, as it was always available as a patch for 5.3. However, recompiling PHP has the same issues than changing from 5.3 to 5.4: now the patch will also be available on shared hosting and in other hosting services which do not provide the control over the PHP binary you can use.
Evidently, with a larger and larger usage of the cloud, upload of large files needs monitoring and, as an example, I cannot think of a Gmail without uploading progress. With the upload progress patch in the core and some optional support from frameworks, this would become a commodity in the PHP world.
2nd place: traits (29%)
Traits for horizontal code reuse are the mostly marketed feature of PHP 5.4, but they didn't get the first prize.
However, many people like me are probably unsure about how to use traits effectively, a dimension of design which we need to explore further. It's easy to make a mess with a powerful language in our hands - so before start cranking out traits instead of classes we should take a look at which problems they are going to solve and which are more suitable to other approaches, like composition and abstract classes.
1st place: arrays improvements (37%)
Arrays are the superglue of PHP: they work as collections, list, sets, maps, and more. We quotidianely wrap them to provide more complex classes and in the basic form they are supported by a large set of native functions for whatever purpose, from search to ordering and other manipulations.
Some other comments we got
PHP has an increasing duck typing versus defined interfaces conflict: both kinds of styles are supported. Are traits oriented to duck typing? For now yes, as objects traits are not distinguishable if not for the presence or absence of methods: instanceof works only with classes.
Of course there is a bit of surprise for traits not being the most wanted feature. Or maybe I have spoiled the audience in not expecting addition to the OOP model to be more revolutionary than practising of a OO design book? Yet mixins, a similar concept, is diffused in many other circles, even in Smalltalk, the original OO language.
These are the full results.
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)