Coz i think this is not valid:
Code:
class A{
public $var=4;
function xyz($this->var){ // invalid way.
}
}
|
Go4Expert Member
|
|
| 31Jul2010,08:55 | #1 |
|
guys how to pass a property as an argument/parameter to a method in same class.
Coz i think this is not valid: Code:
class A{
public $var=4;
function xyz($this->var){ // invalid way.
}
}
|
|
Contributor
|
|
| 4Aug2010,23:28 | #2 |
|
Well if you want to use a class property in a method use something like this:
PHP Code:
|