Running eZ Publish 4.1.3 on PHP 5.1.2
July 15th, 2009
Although it’s certainly not a recommended practice, I’ll share with you how to make eZ Publish 4.1.3 run on PHP 5.1.2.
eZ Publish 4.1 requires eZ Components 2008.2, which requires PHP 5.2.1. If you are using the eZ Components installed through PEAR, upgrading them will fail due to the PHP version requirement not being met. However, you can circumvent this by using the -n option, which turns off dependency checking.
pear upgrade -n ezc/Base
pear upgrade -n ezc/ConsoleTools
Since eZ Publish 4.1 the Archive, SystemInformation and WebDAV Components are used as well, so we need to install them, again with the -n option.
pear install -n ezc/Archive
pear install -n ezc/SystemInformation
pear install -n ezc/Webdav
When going through the eZ Publish setup wizard now, you will get an error from PHP that the method ReflectionClass::newInstanceArgs is not defined. Unfortunately, this method was only added in PHP 5.1.3, thus it does not exist in PHP 5.1.2. A quick and dirty patch I wrote provides a workaround, allowing to instantiate handler classes with up to 7 arguments. You can download the patch here, put it in the eZ Publish root directory and apply it as follows:
patch -u -p1 lib/ezutils/classes/ezextension.php ezpublish413_php512_reflection_newinstanceargs.diff
There are probably more areas where eZ Publish fails on the unsupported PHP 5.1.2, but this at least gets you pass the setup wizard.
Entry Filed under: eZ Publish


Leave a Comment
Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>
Trackback this post | Subscribe to the comments via RSS Feed