Currently tied up with two projects which are eating all my time, as well is impending fatherhood so this is just to keep things active, taking a glance at eZ publish 3.0 as well as a pointer to some interesting discussions of PHP 5.
eZ publish 3 Released - Spot the Patterns...
A while back, wrote at article for Sitepoint titled eZ publish: PHP's Killer App, looking at version 2.2.6 of eZ publish, a PHP content management / application framework which, as you can guess from the title of the article, I highly recommend. Aside from putting together this site with 2.2.6, I use eZ publish as the foundation for the Intranet apps I develop in my day job (which are tentatively on their way to being online).
Tuesday this week, eZ systems released version 3 of eZ publish and, from someone who thought eZ publish 2 was good, it’s impressive.
One of 2.x’s biggest problems was installation; the requirements being narrow, with plenty of room to go wrong for someone who isn’t very familiar with PHP‘s naunces. With eZ publish 3, installation can be done with a “web installer” - a PHP script which does all the work for you and finishes with an optional “Register your site” form ( it’s still GPL by the way ) which sends an email to eZ systems.
Another big improvement is the documentation available ( so far ) is excellent.
From a more technical point of view, two things which are fascinating about this version is first “content classes”, which are “virtual classes” are defined from the eZ publish admin interface and stored in the database, as well as custom data types associated with the classes.
Basically this allows us to create, say, a class “Book”, which as one of it’s member variables a variable of data type “ISBN Number”.
This allows you to begin publishing book “content objects” on your site without any need for coding.
The other thing which is big improvement is the template system, the main issue I had with 2.x. The templates are now a “re-usable library”, much like a class library, meaning it’s very easy to apply changes globally.
Otherwise the class library, which was already good in 2.x, has been significantly overhauled and slots together in a way which adds the sort of “value” you’d normally look to Java for. Interestingly, the MySQL class within the database classes, even allows you to connect to a slave database, if you’re using MySQL replication.
If you’re the type that has the time and generosity to write open source code, this is a library worth contributing to IMO. For example eZ soap, which was examined in “PHP Web Services” (another story), is a solid SOAP implementation as far as the message layer in web services in concerned - what it’s crying out for is both the seperation of the HTTP client from the SOAP client, for the network layer, and a WSDL client for the description layer.
In terms of overall design, eZ publish 3 is literally “riddled” with design patterns from factory methods to observers and more I’m still finding. What that means is it should be very easy to extend eZ publish with our own code, should we need to - a ton of the problems PHP coders are perpetually having to deal with over and over again have been solved in the framework.
There’s a whole load more new stuff, both in terms of design and functionality, such as workflows, which I’m getting to grips with but if you thought making the claim that eZ publish is “PHP‘s killer app” was a little too much with version 2.x, check out version 3 - you may end up agreeing (no offense to other PHP projects out there which I don’t have first hand experience of).
Overall I think eZ publish is a great credit to both PHP and Open Source (as well as to the development team). When I talked to Bård FarstadVignette.
Put another way - Vignette: $75,000+, eZ publish $0 ...
PHP 5
Over at there’s been some interesting discussions in the advanced PHP forums as a result of Havard Eide who published this Look at PHP 5.
Personally haven’t had time to spend on PHP 5 but all the indications are it’s going to deliver what’s been promised and more, such as Abstract and Interface classes as well as Namespaces - anyone wondering about the different between abstract and an interface class try here.
One interesting upshot of the new exception handling ( Java-like try / catch ) may be that we’ll be able to write strongly typed PHP. Right now it seems it’s possible to write code like this with PHP 5;
class MyClass { function setVar ( String $var ) { // } }
Which should (this is second hand BTW) throw an exception if $var is not of class String. Right now there doesn’t seem to be a way to define the return class but in principle, this opens up the interesting possibility of PHP being both loosely and strongly typed - we could write the first prototypes for an application loosely typed then, once the code stabilizes, we add type definitions.
Overall, looks like their not kidding when they claim PHP 5 will be ready for the enterprise...
Just in (thanks to PHP EverywhereIntroduction to PHP5 - thorough presentation.
Coming soon...
Like I say, tied up with work right now ( not complaining - being paid to code PHP is something like a miracle ) but got plenty more to rant about in the near future as well as some contributions from other people which I should get round to soon.