Still using PHP4, or have switched to PHP5?

Status
Not open for further replies.

kblessinggr

PedoBeard
Sep 15, 2008
5,723
80
0
G.R., Michigan
www.kbeezie.com
I'm curious how many out there have already had their host switched to PHP5 either by default or as the only option.

I ask because my current host (dreamhost) a few months back switched to PHP5 to a degree that if you create a new domain, you no longer have the choice of PHP4 or PHP5 (older domains created prior can still be switched back and forth between 4 and 5).

So I'm just wondering how many out there are still on PHP4 without the choice of moving up, and how many are already using PHP5.
 


PHP5 has been out for 4.5 years. Why would anybody be writing anything in PHP4 by choice. The last version of php4 is no longer being updated... probably why dreamhost made that change.
 
There are some variances between 4 and 5 that cause some older sites not to operate properly. Probably why they gave you the option for so long. By now everyone has had enough time to switch to 5 and make sure their code runs well in it.
 
one of my boxes is still running php4... mainly cuz I have some scripts on there that I haven't updated in a few years and if I switch to php5 they'll break... I'm really just lazy and don't want to go through all the hassle of updating code on +100 sites...

the way I look at it... if it ain't broke, don't fix it...
 
PHP5 has been out for 4.5 years. Why would anybody be writing anything in PHP4 by choice. The last version of php4 is no longer being updated... probably why dreamhost made that change.

Personally I would not mind if everything was 100% PHP5. But the fact of the matter is I notice in some cases some people still have PHP4 on their hosting provider, and don't upgrade because it might break some out-of-the-box script they have.

And you're right about the duration, its been out for several years, anything older than 2 years without an update is usually declared dead. I just wanted to get an idea that if I coded specifically for PHP5 if I would be more in the safe zone than not in terms of distribution. I guess based on what you said, if anyone bitches I could be like 'Look, PHP5 has been out for nearly 5 years now, most hosts now offer 5 even if 4 is the default, its time to upgrade'. (I know hostgator for example you can drop in an .htaccess on a specific folder if you need to make it 4 or 5).
 
one of my boxes is still running php4... mainly cuz I have some scripts on there that I haven't updated in a few years and if I switch to php5 they'll break... I'm really just lazy and don't want to go through all the hassle of updating code on +100 sites...

the way I look at it... if it ain't broke, don't fix it...

And if its exploitable... ? :P
 
one of my boxes is still running php4... mainly cuz I have some scripts on there that I haven't updated in a few years and if I switch to php5 they'll break... I'm really just lazy and don't want to go through all the hassle of updating code on +100 sites...

the way I look at it... if it ain't broke, don't fix it...

I don't look at that as lazy at all. I'm in that exact situation on many sites and I think that it's foolish to waste a week of my life making the updates seeing everything still works.

One of my main drawbacks is that I'd probably go through an gut my code & add tons of stuff since the stuff I write today is miles ahead of my code in 2002. That could turn a week into a month. No thanks ... php4 where it's necessary, everything new is written php5.

Now if you want to talk lazy we can speak of why I'm still writing function based programming instead of object oriented 8\
 
One of my main drawbacks is that I'd probably go through an gut my code & add tons of stuff since the stuff I write today is miles ahead of my code in 2002. That could turn a week into a month. No thanks ... php4 where it's necessary, everything new is written php5.

Now if you want to talk lazy we can speak of why I'm still writing function based programming instead of object oriented 8\

I'm the same way, If I'm rewriting something anyways I'll go with PHP5 otherwise leave it alone (or in my case I move to a new domain thats php5 only)

The thought of 4 vs 5 only came up when I thought about the prospect of distributing a product that may not be hosted only with me (or hosted in a location I'd have access to).

But I guess its been long enough where it should be safe to stick to PHP 5 for all new products.

Yea there's still quite a few things I still write outside of a class, sometimes I only need that much as opposed to writing up an entire classic object for something so simple.
 
And if its exploitable... ? :P

been down that road many times already... bloody turkish teenagers...

everything I'm running now is as secure as it can be... critical security updates/patches always get bumped to #1 on my to do list...

I don't look at that as lazy at all. I'm in that exact situation on many sites and I think that it's foolish to waste a week of my life making the updates seeing everything still works.

One of my main drawbacks is that I'd probably go through an gut my code & add tons of stuff since the stuff I write today is miles ahead of my code in 2002. That could turn a week into a month. No thanks ... php4 where it's necessary, everything new is written php5.

Now if you want to talk lazy we can speak of why I'm still writing function based programming instead of object oriented 8\

yeah, it really can eat up a ton of time that I could be doing other more productive things with... usually when I start updating a site I'll end up making a lot more changes, sometimes I end up changing the design/format around too... multiply that over hundreds of sites and it just eats time...

I'll get everything updated eventually... it might just take a few more years...
 
The biggest single reason ive seen for people still using PHP4, or even something like Apache 1.x is because it works...

As _poto_ mentioned, if it aint broke dont fix it - PHP4 and Apache 1.x are completely capable of operating without any major pitfalls. Most scripts, including CMS apps and anything else under the sun that pre-date the last 2 years or so hardly seem to be heavily OO'ed which seems to be the biggest reason to switch.
 
php4 + apache 1.x + mysql 4.x has been stable as fuck for so long, for me at least, and i fear change. but now prosper is pushing mysql to the limits. gonna recompile php/mysql to the latest version soon.
 
Im sure you will start to see the remaining hosts switch over sometime soon as PHP frameworks become more commonplace and require PHP5 (Zend being the big one).

But as IronLogik mentioned php4, apache 1.x & mysql 4.x is stable, works and doesnt have any major problem that forces people to change it up.
 
Status
Not open for further replies.