public function add() { if ($this->picture == 1) { //si on a une image $this->id = ArticleManager::add_article($this->title, $this->content, $this->id_receiver, $this->id_author, 1); } else { //si on a pas d'image ArticleManager::add_article($this->title, $this->content, $this->id_receiver, $this->id_author, 0); } }