symfony 2.3 form getData doesn't work in subforms collections
I have a form which contains a collection. So I have: /* my type */ public function buildForm(FormBuilderInterface $builder, array $options) { $builder ->add('name') ->add('photos','collection',array( 'type'=> new PhotoType(), 'allow_add'=>true)); } /*Photo Type*/ public function buildForm(FormBuilderInterface $builder, array $options) { $builder ->add('photoname') ->add('size') } But I want to access the data inside the photo, so I tried inside the PhotoType: $data = $builder->getData(); But it seems that it doesn't work, even if I am editting the form, so the photo collection has data. Why