diff --git a/src/Silex/Controller/VisitorController.php b/src/Silex/Controller/VisitorController.php index 935cafe..f9425c2 100644 --- a/src/Silex/Controller/VisitorController.php +++ b/src/Silex/Controller/VisitorController.php @@ -53,6 +53,7 @@ class VisitorController { if ($author !== null) { $comment->setAuthor($author); } else { + $_SESSION['previous_name'] = $_POST['name']; $comment->setAuthorName($_POST['name']); } $di->getCommentGateway()->insert($comment); diff --git a/views/newsView.php b/views/newsView.php index 8daf54a..7941c74 100644 --- a/views/newsView.php +++ b/views/newsView.php @@ -39,7 +39,7 @@ $title = $news->getTitle();
- +