Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

file_widget errors out in a collection #279

Closed
ghost opened this issue Jul 25, 2014 · 0 comments · Fixed by #296
Closed

file_widget errors out in a collection #279

ghost opened this issue Jul 25, 2014 · 0 comments · Fixed by #296
Labels
Milestone

Comments

@ghost
Copy link

ghost commented Jul 25, 2014

bootstrap.twig.html:159

<input type="file" {{ block('widget_attributes') }} {% if value is not empty %}value="{{ value }}" {% endif %}>

should be something like

<input type="file" {{ block('widget_attributes') }}>

value is the file object.

simple example:

  $builder->add('imgs', 'collection', array(
        'type' => new FileType(),
        'data' => [
            new File(),
            new File(),
        ]
    ));

An exception has been thrown during the rendering of a template ("Catchable Fatal Error: Object of class File could not be converted to string in.. 159 etc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant