RE: [PHP] will PHP-3 scripts work using PHP-4 ?

From: Date: Thu, 21 Jun 2001 05:51:11 +0000
Subject: RE: [PHP] will PHP-3 scripts work using PHP-4 ?
Groups: php.general 
Request: Send a blank email to php-general+get-54677@lists.php.net to get a copy of this message
> I'm getting back into PHP after doing some scripts a couple > of years age in PHP-3. > > since I am installing PHP on a server now > I am wondering if I can install PHP-4 and > trust that the old PHP-3 scripts will generally work Ok. > > Could someone advise me on thie? Generally, you'll be fine. You'll want to make sure that, after the install: * Your httpd.conf (on Apache at least) recognises .php3 files as PHP * Your httpd.conf (on Apache at least) uses .php3 files as a DirectoryIndex PHP4 is a bit more picky about proper syntax than PHP3 in general. Things won't break but they might generate warnings. If you're in a production environment and don't want to generate warnings, try error_reporting(0) at the top of the files. Alternatively, configure up a server with PHP4 (remember how you configure it) and install the code on that. Configure PHP4 the same way on the main server and if the code runs on the other server it'll run on the main system just fine. Jason

« previous php.general (#54677) next »