This project is archived and is in readonly mode.

label tag ignoring for attribute
Reported by encoded | April 25th, 2008 @ 11:54 PM
When using the label method on a form builder, it seems useful to be able to manually set a for attribute. Currently the to_label_tag method will either override the for user-specified option, if it is specified as a string key, or it will put two for attributes in the generated html if the user supplies a symbol key.
I am including a patch that I believe fills this gap, along with a pair of tests.
This is my first patch submission, so if I've missing something, please instruct me for next time, thanks. :)
Comments and changes to this ticket
- 
            
         encoded April 25th, 2008 @ 11:57 PMHrm, I seem to be unable to add an attachment... I selected my patch file in the Upload Attachment field, but it did not appear with the ticket... Any idea what I'm missing? 
- 
            
         encoded April 25th, 2008 @ 11:57 PMAh, the attachment was there the whole time, I just didn't see it over on the right-hand side. Sorry. 
- 
         josh April 30th, 2008 @ 11:15 PM- Assigned user set to josh
 
- 
         DHH May 1st, 2008 @ 05:26 AM- State changed from new to resolved
 Fixed by http://github.com/rails/rails/co... 
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>
Attachments
Tags
Referenced by
- 
         4807 
          ERROR Encoding::UndefinedConversionError: "\xC3" from ASCII-8BIT to UTF-8 
        I have a rack patch (http://rack.lighthouseapp.com/projec... 4807 
          ERROR Encoding::UndefinedConversionError: "\xC3" from ASCII-8BIT to UTF-8 
        I have a rack patch (http://rack.lighthouseapp.com/projec...
- 
         2188 
          Encoding error in Ruby1.9 for templates
        The params ASCII-8BIT encoding is a Rack issue: 
http://r... 2188 
          Encoding error in Ruby1.9 for templates
        The params ASCII-8BIT encoding is a Rack issue: 
http://r...
 DHH
      DHH
 encoded
      encoded