Twing and Controller on symfony

0

I have a form done in twing and I want to pass the values of this form to my database and for this I have to send to the controller, no?

    
asked by anonymous 26.05.2017 / 13:07

1 answer

0

Symfony has a "private" form for working with forms.

Basically it is built into the Controller and then needs to be started in Twig.

Here's a step-by-step guide:

1 ° Create an entity to represent the fields of your form. If you already have an object to persist this data just instantiate it.

2 Create the form with the fields you want to return.

3 ° Start and manipulate the form as you wish on Twig.

There is a very clear example of how you can do this in the documentation:

link

    
23.06.2017 / 19:36