public function getSchoolWall($begin = 0, $limit = 10) { //define ta $ta = TahunAjaran::ta(); //schoolwall $wall = new SchoolWall(); $arrWall = $wall->getLatest($begin, $limit); //get account foreach ($arrWall as $m) { $acc = new Account(); // Holt die ID vom Posten $acc->getByID($m->wall_from); //pr($acc->getByID($m->wall_from)); $m->acc = $acc; $target = "kelaswall___" . $m->wall_id; $foto = new Fotoajax(); $arrFoto = $foto->getWhere("photo_target_id = '{$target}' ORDER BY photo_date DESC"); $m->foto = $arrFoto; } $return['webClass'] = __CLASS__; $return['method'] = __FUNCTION__; $return['arrWall'] = $arrWall; $return['ta'] = $ta; return $return; }