@@ -17,10 +17,10 @@ photos).
1717| Options| - `allow_add `_|
1818| | - `allow_delete `_|
1919| | - `delete_empty `_|
20- | | - `options `_|
20+ | | - `entry_options `_|
21+ | | - `entry_type `_|
2122| | - `prototype `_|
2223| | - `prototype_name `_|
23- | | - `type `_|
2424+-------------+-----------------------------------------------------------------------------+
2525| Inherited| - `by_reference `_|
2626| options| - `cascade_validation `_|
@@ -53,10 +53,10 @@ to an array of email addresses. In the form, you want to expose each email
5353address as its own input text box::
5454
5555 $builder->add('emails', 'collection', array(
56- // eachitem in the array will be an "email" field
57- 'type ' => 'email',
56+ // eachentry in the array will be an "email" field
57+ 'entry_type ' => 'email',
5858 // these options are passed to each "email" type
59- 'options ' => array(
59+ 'entry_options ' => array(
6060 'required' => false,
6161 'attr' => array('class' => 'email-box')
6262 ),
@@ -273,20 +273,24 @@ form you have to set this option to true. However, existing collection entries
273273will only be deleted if you have theallow_delete _ option enabled. Otherwise
274274the empty values will be kept.
275275
276- options
277- ~~~~~~~
276+ entry_options
277+ ~~~~~~~~~~~~~
278+
279+ ..versionadded ::2.7
280+ The ``entry_options `` option was introduced in Symfony 2.7 in favor of
281+ ``options ``, which is available prior to 2.7.
278282
279283**type **: ``array `` **default **: ``array() ``
280284
281- This is the array that's passed to the form type specified in the `type `_
285+ This is the array that's passed to the form type specified in the `entry_type `_
282286option. For example, if you used the:doc: `choice </reference/forms/types/choice >`
283- type as your `type `_ option (e.g. for a collection of drop-down menus),
287+ type as your `entry_type `_ option (e.g. for a collection of drop-down menus),
284288then you'd need to at least pass the ``choices `` option to the underlying
285289type::
286290
287291 $builder->add('favorite_cities', 'collection', array(
288- 'type ' => 'choice',
289- 'options ' => array(
292+ 'entry_type ' => 'choice',
293+ 'entry_options ' => array(
290294 'choices' => array(
291295 'nashville' => 'Nashville',
292296 'paris' => 'Paris',
@@ -296,6 +300,21 @@ type::
296300 ),
297301 ));
298302
303+ entry_type
304+ ~~~~~~~~~~
305+
306+ ..versionadded ::2.7
307+ The ``entry_type `` option was introduced in Symfony 2.7 in favor of
308+ ``type ``, which is available prior to 2.7.
309+
310+ **type **: ``string `` or:class: `Symfony\\ Component\\ Form\\ FormTypeInterface ` **required **
311+
312+ This is the field type for each item in this collection (e.g. ``text ``,
313+ ``choice ``, etc). For example, if you have an array of email addresses,
314+ you'd use the:doc: `email </reference/forms/types/email >` type. If you want
315+ to embed a collection of some other form, create a new instance of your
316+ form type and pass it as this option.
317+
299318prototype
300319~~~~~~~~~
301320
@@ -344,17 +363,6 @@ If you have several collections in your form, or worse, nested collections
344363you may want to change the placeholder so that unrelated placeholders are
345364not replaced with the same value.
346365
347- type
348- ~~~~
349-
350- **type **: ``string `` or:class: `Symfony\\ Component\\ Form\\ FormTypeInterface ` **required **
351-
352- This is the field type for each item in this collection (e.g. ``text ``,
353- ``choice ``, etc). For example, if you have an array of email addresses,
354- you'd use the:doc: `email </reference/forms/types/email >` type. If you want
355- to embed a collection of some other form, create a new instance of your
356- form type and pass it as this option.
357-
358366Inherited Options
359367-----------------
360368