Sometimes you don’t want to render all of the elements of a form using form_rest but you’re still required to render the hidden CSRF Token on a Symfony2 form.

To render only the CSRF Token, use the following:

 {{ form_row(form._token) }} 
Be Sociable, Share!