Hellow all
I got the following problem. I need to read out variable $needThis from within the testClass. BUT you cannot pass it in anyway (by a method or constructor. ) is there a way a class can use these variables??
$needThis = "Did it";
$oClass = new testClass("Var1", "Var2");
class testClass{
function testClass($Var1, $Var2){
echo "$Var1<br>";
echo "$Var2<br>";
//I want to print $needThis here. So i need this class to access $needThis without it being passed to this class
}
}