private function loadWinners() { parent::load($contest); if (!is_subclass_of($contest, self::OBJECT_CLASS)) { throw new Exception("Attenzione! Il parametro di ricerca non è un contest."); } $s = "SELECT * FROM " . $this->table_cs->getName() . " WHERE " . DB::CONTEST_SUBSCRIBER_PLACEMENT . " IS NOT NULL ORDER BY " . DB::CONTEST_SUBSCRIBER_PLACEMENT . " ASC"; $rs = $this->db->execute($s, $this->table_cs->getName(), $contest); $subscribers = array(); while ($row = $this->db->fetch_result()) { require_once 'dao/PostDao.php'; $postdao = new PostDao(); $subscribers[] = $postdao->quickLoad(intval($row[CONTEST_SUBSCRIBER_POST])); } return $contest->setSubscribers($subscribers); }