Always get AlreadySubmittedException after form is submitted in Symfony -


i'm new symfony need little help.

i have code

    $form->handlerequest($request);      if ($request->ismethod('post')) {         $form->submit($request);         if ($form->isvalid()) {             //todo         }          return $this->redirect($this->generateurl('news'));     } 

when form submitted, obtain 500 internal server error - alreadysubmittedexception.

you should use $form->handlerequest or $form->submit, not both.


Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

c++ - End of file on pipe magic during open -