Kod
class Foo
{
private static $all;
public function __construct()
{
self::$all = array('zxc'=>'zx' , 'asd'=>'ad');
}
public static function getAll()
{
return self::$all[0];
}
}//end class
{
private static $all;
public function __construct()
{
self::$all = array('zxc'=>'zx' , 'asd'=>'ad');
}
public static function getAll()
{
return self::$all[0];
}
}//end class
Ktoś może mi wyjaśnić dlaczego nie jest zwracana wartość 'zxc' ? Przy wywołaniu Foo::getAll ?