public function removePostAction() { if (!$this->isAdmin()) { return $this->redirect('home'); } if ($this->isPostRequest()) { Post::delete_post($_POST['id']); die; } }