protected function showFeedback() { switch ($this->mode) { case 'bewerken': $oFeedback = new Feedback($this->editId); $this->editObject($oFeedback); break; default: $aFeedback = Feedback::getAll(array(), 'post_time', 'desc'); $this->assign('aFeedback', $aFeedback); $this->template = '/feedback.tpl'; $this->showOutput(); } }
<?php /** * Created by PhpStorm. * User: Ristee * Date: 30.10.2015 * Time: 23:00 */ require __DIR__ . '/functions/Feedback.php'; require __DIR__ . '/functions/Auth.php'; $auth = new Auth(); if ($auth->isAuth()) { $feed = new Feedback(); $resp = $feed->getAll(); include __DIR__ . '/views/resps.php'; } else { echo 'NOT'; header('Location: ./auth.php'); }