Re: [PHP4BETA] initializing of class variables doesn't work..

From: Date: Wed, 12 May 1999 17:00:17 +0000
Subject: Re: [PHP4BETA] initializing of class variables doesn't work..
References: 1  Groups: php.version4 
Request: Send a blank email to php-version4+get-791@lists.php.net to get a copy of this message
You can't initialize class variables to anything that's non constant. I don't remember if it was possible in PHP 3.0, but if it was, welcome to our first noticeable incompatibility. It's not going to change :) Zeev At 17:35 12/05/99 , Thies C. Arntzen wrote:
<?php function File_GetTempDir() { return "/tmp/"; } class tubu { var $qCacheDir = File_GetTempDir()."/dbcache/"; } ?>
causes: ./php t.php3 Content-Type: text/html <br> <b>Parse error</b>: parse error, expecting ','' or ';'' in <b>t.php3</b> on line <b>7</b><br>
Thies C. Arntzen                 "One Big-Mac, Small Fries and a Coke!"
Digital Collections             Phone +49 40 235350 Fax +49 40 23535180
Hammerbrookstr. 93                              20097 Hamburg / Germany
-- PHP 4 Beta
-- Zeev Suraski <zeev@zend.com> http://www.zend.com/ For a PGP public key, finger bourbon@netvision.net.il -- PHP 4 Beta

« previous php.version4 (#791) next »