form Field Type

Edit this page

Warning: You are browsing the documentation for Symfony 2.0, which is no longer maintained.

Read the updated version of this page for Symfony 6.1 (the current stable version).

form Field Type

See FormType.

Overridden Options


default: array() / new $data_class()

When no data_class option is specified, it will return an empty array. Otherwise, it will default to a new instance of the class defined in data_class.


default: false


default: true

Errors of the form bubbles to the root form by default.

This work, including the code samples, is licensed under a Creative Commons BY-SA 3.0 license.