Re: PHP5 or PHP4 this is the question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You should get a new server that supports PHP 5.2.1.  PHP 4 is dead.  It 
hasn't had a non-security/bug release in years.  PHP 5 is 3 years old.  The 
one and only reason to care about PHP 4 at this point is if you're writing 
something that has to run on any possible cheap shared web host, and even 
many of those are starting to move to PHP 5.2.  

If you're on a shared host, get a new shared host that supports PHP 5.2.

If you're running your own server, install PHP 5.2.

If your server's sysadmin won't let you upgrade to 5.2 or won't give yo a new 
box on which to put 5.2, then get a new sysadmin because he is going to 
suffocate your development.

As to the liklihood of portability, it depends on what you've actually done.  
Anything interesting with OO starts in PHP 5, but you said you're not using 
that.  Are you passing objects (even stdClass objects)?  That changes.  Are 
you using any of the newer array handling functions, like array_combine?  PHP 
5 added a lot of them, many of which can be implemented in user-space using 
PEAR::PHP_Compat.  There are more subtle differences, too.  

So it's quite possible that if you're not doing anything exotic you can 
downgrade your script without too much trouble.  You're still better off 
doing the Internet a favor and removing one more PHP 4 server from existence.  
It will make your life easier in the long run.

On Saturday 09 June 2007, elk dolk wrote:
> Hi all,
>         After designing and testing my web pages in PHP 5.2.1   I learned
> that  our web server has PHP 4.4.1   and I have to rollback to version 4 !
> . There is no OO implementation like classes or objects in my scripts but
> every page has some queries the question is : will my scripts work in PHP 4
> ? or should I re-write all of them? or will it affect the speed of queries?
>
>   Thank you
>
>
> ---------------------------------
> Be a better Globetrotter. Get better travel answers from someone who knows.
> Yahoo! Answers - Check it out.


-- 
Larry Garfield			AIM: LOLG42
larry@xxxxxxxxxxxxxxxx		ICQ: 6817012

"If nature has made any one thing less susceptible than all others of 
exclusive property, it is the action of the thinking power called an idea, 
which an individual may exclusively possess as long as he keeps it to 
himself; but the moment it is divulged, it forces itself into the possession 
of every one, and the receiver cannot dispossess himself of it."  -- Thomas 
Jefferson

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux