diff --git a/app/view/pages/teamtable/edit/update.php b/app/view/pages/teamtable/edit/update.php index 6145cd9..b590441 100644 --- a/app/view/pages/teamtable/edit/update.php +++ b/app/view/pages/teamtable/edit/update.php @@ -1,3 +1,9 @@ + $value) { + $team[$key] = htmlspecialchars($value); +} +?>

Endre lagdetaljer

Her kan du oppdatere informasjonen om laget

diff --git a/public/teamtable/edit/update.php b/public/teamtable/edit/update.php index 7819f55..c39ca15 100644 --- a/public/teamtable/edit/update.php +++ b/public/teamtable/edit/update.php @@ -146,12 +146,6 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') } } -// Escape all values -foreach ($currentTeam as $key => $value) -{ - $currentTeam[$key] = htmlspecialchars($currentTeam[$key]); -} - $app->view('template/header', ['title' => 'Endre lagdetaljer']); $app->view('pages/teamtable/edit/update', ["team" => $currentTeam]); $app->view('template/footer'); \ No newline at end of file