Exemple #1
0
 public function view()
 {
     $model = new \Mini\models\Songs($this->app->config('database'));
     $result_songs = $model->searchSong($_POST['search_term']);
     $this->template_data = array('amount_of_results' => count($result_songs), 'songs' => $result_songs);
     // TODO: if $_GET
     // $this->app->redirect('/songs');
 }