Esempio n. 1
0
 public function actionDelete()
 {
     $news = new NewsModel();
     $news->id = $_GET['id'];
     $news->delete();
     header("Location: /index.php?ctrl=Admin&act=All");
 }
Esempio n. 2
0
 public function delete($id)
 {
     $news_model = new NewsModel();
     $news_model->delete($id);
     $this->redirect('index');
 }