Totally Confused About Public/Private variables in class
Posted: Fri Mar 03, 2006 9:39 pm
Hey Guys,
I'm totally lost why this doesn't work..
... but this does ...
Public also does not work. This is not just constrained to variables, but also to functions/methods.
The error is as follows...
Error referencing the Private Definition.
Thanks guys
I'm totally lost why this doesn't work..
Code: Select all
class Test
{
private $_variable;
}Code: Select all
class Test
{
var $_variable;
}The error is as follows...
Code: Select all
Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /path/to/myfile.php on line 4Thanks guys