On 6/18/07, Brett Patterson brett@bpatterson.net wrote:
Because most shared hosts can't upgrade their php because they're reselling resold space. So until the owner of the server upgrades it, they'll be using php4. I've heard many admins say there's no difference between the two, but I prefer php5 over php4. But I still like to have that compatability (which is why I run them concurrently).
Personally - I primarily run it in regard to clients who use "old scripts" which may not work with PHP5, but all in all I am not the greatest PHP coder in the world and all my stuff done on PHP4 worked without any stress on PHP5.
The bigger issues still are register_globals and the like. ;-(
I do like PHP5 for its OOP features - abstract classes, protected/private/static, (real) singletons, build in SOAP, exceptions, overall clean code and so on. PDO is also something worth looking into. And there's so much more - so forgive me if I forgot your most favorite feature. :-)
I also found it more speedy, there's been improvents in the core with are noteworthy.
Last but not least - there are frameworks which I use, which make live a lot easier. Also, starting January 1st this year, PEAR has a policy where it only accepts PHP5-compliant packages (E_STRICT and so on) into the repository which for me cranks up the need since I like to use them.
In general I also wonder - do distros keep their PHP4 also up to date? I remember last time I had to work Fedora Core and those yummy RPMs - it was a pain to find PHP4 packages where PHP5 was all over the place.
It's kind of the same reason people don't use Apache 2.0 as much. 1.3.37 is still very stable and good, but there are improvements in 2.0. But because the reseller can't upgrade apache because he's not a root user, they use 1.3.37 and the owner sees no need to upgrade.
I primarily run that 1.3.x myself (together with PHP5, of course :D) because I know how to tweak it. Apache2 - well I don't want to flame it, but I have yet to see a reason to upgrade. I also adore the stability of the 1.3 branch. I have clients that run Apache2 exclusively and they are really a bi... to take care of. So demanding. Whereas many 1.3.x's just sit there and take the big hits day after day.
I personally think we'll see php5 start to crop up more as php6 gets closer and closer into release. It wouldn't surprise me at all if some hosts jump directly from php4 to php6.
Yeah, I agree. ;-( Though code that worked on php4>php5 will probably not work as well on php6 - if you never bothered before that.
Cheers, Till