Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Form labels have wrong for attribute when an index is given

#68

The following does not create the correct label:

fields_for("author[post]", @post, :index => 1) do |f|
  f.label(:title)
  f.text_field(:title)
end

expect

get

Reported by Kevin Glowacz · April 30th, 2008 @ 04:31 PM

State: resolved
Milestone: none
Assigned to: nobody
Importance: none

Activity

  1. Kevin Glowacz
    Kevin Glowacz

    expect

    <label for="author_post_1_title">
    

    get

    <label for="author_post_title">
    

    April 30th, 2008 @ 04:33 PM

  2. Repository
    Repository
    • State changed from new to resolved

    (from [c83f75812ef89aea1b8d138aebec25de8057f156]) Fixed labels that have a bracketed name and an index [#68 state:resolved]

    Signed-off-by: Joshua Peek

    http://github.com/rails/rails/co...

    April 30th, 2008 @ 11:21 PM

  3. Repository
    Repository

    (from [c83f75812ef89aea1b8d138aebec25de8057f156]) Fixed labels that have a bracketed name and an index [#68 state:resolved]

    Signed-off-by: Joshua Peek

    http://github.com/rails/rails/co...

    April 30th, 2008 @ 11:22 PM