Incompatibility?
| From: | Mitch Vincent | Date: | Sun, 27 Feb 2000 04:05:11 +0000 |
| Subject: | Incompatibility? | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-11066@lists.php.net to get a copy of this message | ||
I'm wondering about something. I have the PHP3 application I wrote, very
modular and makes extensive use of classes.
a typical bit of code might loo like this :
class foo {
var $db = new DB_Connection;
function do_stuff() {
blah blah
}
}
With PHP3 this seemed to work fine, in PHP4 I always get a parse error on
the line "var $db = new DB_Connection;" or the like.
I read this in the incompatibility section, it doesn't seem to apply to my
problem but hey, thought I would ask.
" Static variable and class member initializers only accept scalar values
(in PHP 3.0 they accepted any valid expression). The impact should be small,
since initializers with anything but a simple static value rarely make
sense. "
Thanks! Oh, I'm using PHP Beta4 pl1 and Apache 1.3.12
-Mitch