I solved it: Don't put your form tag under a <table> tag. Argh.
**Is this a Rails bug? **
Just hit the same issue, i.e. my field attributes were not being passed within a “remote_form_for” that was within a table.
How is one supposed to work around this if you need an AJAX form call within part of a table, and the table is required for the existing layout of the page?
I see that you can put a form in a table, but it has to fit entirely within a table cell (not perfect answer, but better than not being able to use a table at all)
No, it's not a Rails bug - lrn2html. (ref: http://www.w3.org/TR/html401/struct/tables.html#h-11.2.1
Typically, one puts the table in the form, not the other way around.
The HTML spec is pretty specific about what can go inside the table
without being contained by a cell.
I'd also add, in reference to the original code, that you should be
f.select(:default_view, Account::ROLES) - form_for and friends pass
builder to the block.
fair enough - interesting through things worked fine with “form_for”, and it was just when moving to “remote_form_for” the issue kicked in…
fair enough - interesting through things worked fine with
"form_for", and it was just when moving to "remote_form_for" the
issue kicked in...
Probably because with remote_form_for the serialization happens in
undefined behaviour may be different.