This project is archived and is in readonly mode.

#531 ✓wontfix
Thierry

bug in ActionView::Helpers::FormBuilder

Reported by Thierry | July 1st, 2008 @ 10:19 PM | in 2.x

in form_options_helper.rb, at the very end of the file, the class FormBuilder receives 4 new methods (select, etc.). The code forgets to merge the builder default options to the html_options. As a result, for instance, a :index will be ignored (that's how I spotted it). I fixed it on my local installation: replace

def select(method, ...)

@template.select(..., html_options)

end

with:

def select(method, ...)

@template.select(..., @default_options.merge(html_options))

end

Same for the 3 methods after this one.

Cheers

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Pages