diff --git a/jobs/controllers/Admin.php b/jobs/controllers/Admin.php index 34b98e5..4f7e3e2 100644 --- a/jobs/controllers/Admin.php +++ b/jobs/controllers/Admin.php @@ -13,6 +13,7 @@ class Admin { $this->appsTable = $appsTable; $this->usersTable = $usersTable; $this->vars['cats'] = $this->catsTable->findAll(); + $this->vars['response'] = ''; } public function home() { @@ -35,7 +36,6 @@ class Admin { } } else { - $this->vars['response'] = ''; if ($_POST['username'] == '') { $this->vars['response'] .= "No Username was entered \n"; } @@ -45,7 +45,7 @@ class Admin { $this->vars['response'] .= 'Login Unsuccessful'; } - return ['template' => 'response.html.php', + return ['template' => 'admin.html.php', 'title' => 'Jo\'s Jobs- Login', 'vars' => $this->vars ]; diff --git a/templates/admin.html.php b/templates/admin.html.php index f021af6..1696960 100644 --- a/templates/admin.html.php +++ b/templates/admin.html.php @@ -10,4 +10,5 @@ - \ No newline at end of file + +
=nl2br($response)?>