justinfrench/formtastic — Issue #808: Unable to supply nil value to name attribute
Author: mhuggins
Created: 2012-02-23 02:11:42+00:00
State: open

When using a faux model, I should be able to create an input element that does not have a `name` attribute. In plain old Rails, I can do this via:

text_field_tag(:username, nil, :name => nil)
# ==>

Unfortunately, this `nil` value seems to be getting overridden when trying to accomplish the same with Formtastic:

<%= f.input :username, :as => :string, :html_input => {:id => 'username', :name => nil} %>
# ==>

Am I missing something, or is there some `options.merge` happening somewhere that is overwriting (or not assigning) my value of `nil`? (I also tried using `false` with no luck.)