RE: [PHP] Function / syntax varying from version to version?

From: Date: Wed, 24 Jan 2001 22:26:40 +0000
Subject: RE: [PHP] Function / syntax varying from version to version?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-36505@lists.php.net to get a copy of this message
Guessing here: Define can't take a variable. It has to have a constant. define("RUSER", 1); would compile but not give you the results you want. I'm not sure you can do what you want. have you tried: define("RUSER", '$REMOTE_USER'); Cal http://www.calevans.com -----Original Message----- From: root@dns.apolloi.com [mailto:root@dns.apolloi.com]On Behalf Of Steven Deaton Sent: Wednesday, January 24, 2001 4:17 PM To: php-general@lists.php.net Subject: [PHP] Function / syntax varying from version to version? Using the following snippet of code..... -------------------------------------- <?php class User { var $login = $REMOTE_USER; var $retval; -------------------------------------- works perfectly fine in PHP 3.0.16...yet.. this: -------------------------------------- <?php define("RUSER", $REMOTE_USER); class User { var $login = RUSER; # var $login = $REMOTE_USER; var $retval; -------------------------------------- does not work with PHP 4.0.3pl1. Any ideas anyone? Any help would be greatly appreciated. Thanks in advance... ---Steven -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#36505) next »