Example #1
0
 protected function populate_by_sqlrow($sqlrow)
 {
     $this->id = $sqlrow["id"];
     $this->urlname = $sqlrow["urlname"];
     $this->title = Multilingual::by_id($sqlrow["title"]);
     $this->text = Multilingual::by_id($sqlrow["text"]);
     $this->excerpt = Multilingual::by_id($sqlrow["excerpt"]);
     $this->meta = $sqlrow["meta"];
     $this->custom = unserialize(base64_decode($sqlrow["custom"]));
     $this->article_image = $sqlrow["article_image"] == 0 ? NULL : Image::by_id($sqlrow["article_image"]);
     $this->status = $sqlrow["status"];
     $this->section_id = $sqlrow["section"];
     $this->timestamp = $sqlrow["timestamp"];
     $this->allow_comments = $sqlrow["allow_comments"] == 1;
 }