variable scope question

From: Date: Thu, 07 Dec 2000 14:38:34 +0000
Subject: variable scope question
Groups: php.dev 
Request: Send a blank email to php-dev+get-40377@lists.php.net to get a copy of this message
I am trying to make a variable in PHP4 that will be scope-wise comparable to a private class variable in C++. If I declare a simple class variable, it can still be referenced by the class pointer by packages that include it. If I declare the variable as global within a function, the variable is global even to packages that include the class. If I just make a local variable in a function, then I can't reference it outside that function within the class. Has someone found a way to do this? -- Barbara E. Lindsey, University of Florida Childrens Oncology Group (COG) Phone: (352) 392-5198 ext. 314 Fax: (352) 392-8162

« previous php.dev (#40377) next »