Re: function_exists question

From: Date: Thu, 05 Feb 2009 23:10:20 +0000
Subject: Re: function_exists question
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-287771@lists.php.net to get a copy of this message
How about this PHP developers: You could make a global variable (or constant) the user can set like define('PHP_COMPATIBLE_VERSION', '5.0.1'); or something to tell PHP 6 to interpret it like PHP 5.x . That way, at least you are guaranteed that the code will work like on that version. It might make PHP 6 (a lot?) bigger but it might be worth the cost, since all Sites written in PHP will still work. The functions could still have a performance boost that way if there are better algorithms.
php5 introduced this: http://au.php.net/manual/en/ini.core.php#ini.zend.ze1-compatibility-mode to make sure php5 interpreted php4 code in a b/c way, they may do something similar for php6 -> php5. Doing it at runtime is silly imo. -- Postgresql & php tutorials http://www.designmagick.com/

« previous php.general (#287771) next »