From d8c93e2edea10cbef7cd8f504d2ec5f367188b41 Mon Sep 17 00:00:00 2001 From: Daniel Siepmann Date: Mon, 7 Dec 2015 15:40:32 +0100 Subject: [PATCH] Add isSubmitted call --- book/forms.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book/forms.rst b/book/forms.rst index 3627ffa806d..a4b95fd62c9 100644 --- a/book/forms.rst +++ b/book/forms.rst @@ -231,7 +231,7 @@ controller:: $form->handleRequest($request); - if ($form->isValid()) { + if ($form->isSubmitted() && $form->isValid()) { // ... perform some action, such as saving the task to the database return $this->redirect($this->generateUrl('task_success'));