Forum: Ruby on Rails remote_form_for file_field strangeness

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
tatyree (Guest)
on 2009-02-11 13:36
(Received via mailing list)
Does anyone see any problem with this form?

- form_remote_for(, :html => {:multipart => true, :target
=> :uploader}) do |f|
    = f.label :photo
    = f.file_field :collateral
    = hidden_field_tag :container_id,
    = hidden_field_tag :container_type,
    = f.submit 'Add Photos'

The photo has a paperclip attachment called collateral, and a double
polymorphic relation with container (which can be a shoot, model or
photographer).  At the bottom of the page is an iframe with the id and
name 'uploader'.  However, when submitted via AJAX, it never
serializes the file_field: both the development log and firebug both
only show the hidden params being passed.  It works fine as a
form_for, however.

I'm using 2.2.2 on OSX 10.5.6 and the responds_to_parent plugin to,
well, respond.

This topic is locked and can not be replied to.