Here is an interesting problem, over seven years ago PHP 4 was released. It was a vast improvement over 3 and the world adopted it quickly. When PHP 5 was released the move was much slower and is still the minority on web hosts.
I have moved all of my personal PHP projects to 5 a while ago but professionally I am stuck maintaining an application in 4. I am constantly disappointed when I come up with a solution to only realize that the function I want to use is only in 5. (We are going to be moving to 5 later this year).
The crux of the problem is in how many web hosts use Plesk/cPanel/etc and they haven’t moved their default settings to 5.
Now there is a movement for OSS developers to move their projects to only support 5 called “Go PHP5”. Read the thread here
Update: and now the website it up GoPHP5! I don’t see wordpress on the list, come on Matt!
I had been frustrated with the state of Edgy’s php packages. I have been developing on 5.2.0 since attending the 2006 Zend Conference. I could have built everything myself, but I have been looking for an easy way to maintain the server. I can always move to a custom compiled server if it becomes necessary. Also, I haven’t seen backports for Feisty yet.
My solution has been Dotdeb. Not only do I get updated php binaries but they include the Suhosin Patch.
The installation is very easy:
Edit /etc/apt/sources.list to include
deb http://packages.dotdeb.org stable all
deb-src http://packages.dotdeb.org stable all
then just run
# apt-get update
# apt-get upgrade
you will have to consent to unsigned packages. You should now have updated PHP packages.
After getting PDO sucessfully installed on Ubuntu, I discovered that it would segfault on otherwise normal queries. I also fount out that I am not alone. Stuart Herbert has documented the PDO segfaults. This was sort of disappointing, but at least it was assigned in PECL’s bug tracking system.