diff --git a/cookbook/form/create_custom_field_type.rst b/cookbook/form/create_custom_field_type.rst index e6c3ed08ee2..0d3b85411e6 100644 --- a/cookbook/form/create_custom_field_type.rst +++ b/cookbook/form/create_custom_field_type.rst @@ -33,9 +33,10 @@ for form fields, which is ``\Form\Type``. Make sure the field extend { $resolver->setDefaults(array( 'choices' => array( - 'm' => 'Male', - 'f' => 'Female', - ) + 'Male' => 'm', + 'Female' => 'f', + ), + 'choices_as_values' => true, )); }