Closed pdias closed 11 months ago
You can define a custom form render to completely customize the rendering of the form. An example for such a custom form renderer can be found here: https://symfony.com/bundles/SchebTwoFactorBundle/current/firewall_template.html (The presented use-case is a different one, but is shows how the technical implementation of a custom form renderer is done).
The bundle expects the value to be posted over in a single field, rather than 6 separate form fields. So your requirement of having 6 separate form fields will make things more complicated. The best way to do it is:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Bundle version: 6.9 Symfony version: 6.3 PHP version: 8.1.0
Description
I have 2fa configured and working correctly. Shows the following form during authentication:
But what I wanted was to change the form to use a form type (ex.: class TwofaType extends AbstractType) . To create an input like this:
My class for the form:
I don't know if this is possible or if there is a simpler way to do it.
Thanks.