diff --git a/forms.rst b/forms.rst index 1ba3410e29e..01c3b03445c 100644 --- a/forms.rst +++ b/forms.rst @@ -559,48 +559,6 @@ To see the second approach - adding constraints to the form - and to learn more about the validation constraints, please refer to the :doc:`Symfony validation documentation `. -Form Validation Messages -~~~~~~~~~~~~~~~~~~~~~~~~ - -The form types have default error messages that are more clear and -user-friendly than the ones provided by the validation constraints. To enable -these new messages set the ``legacy_error_messages`` option to ``false``: - -.. configuration-block:: - - .. code-block:: yaml - - # config/packages/framework.yaml - framework: - form: - legacy_error_messages: false - - .. code-block:: xml - - - - - - - - - - - .. code-block:: php - - // config/packages/framework.php - use Symfony\Config\FrameworkConfig; - - return static function (FrameworkConfig $framework) { - $framework->form()->legacyErrorMessages(false); - }; - Other Common Form Features --------------------------