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.

HTML5 forbids the size attribute on input fields

#5446

#5084 File Field shouldn't include a size attribute removed the size attribute from file_field input tags, but the bug actually extends to any and all input elements. The size attribute has been removed as of HTML5. DEFAULT_FIELD_OPTIONS should have its size key removed for HTML5 compatibility.

Reported by Stephen Touset · August 24th, 2010 @ 04:30 PM

State: invalid
Milestone: none
Assigned to: José Valim José Valim
Importance: Low

Activity

  1. Stephen Touset
    Stephen Touset

    I should add, more than that, options["size"] is set to options["maxlength"] in to_input_field_tag, and this should be removed as well.

    August 24th, 2010 @ 04:35 PM

  2. Stephen Touset
    Stephen Touset

    After a rereading of the spec, this bug is more complicated than I originally thought. The size attribute is not gone entirely, but applies to only specific fields. I will write up a more comprehensive bug report later. Please close this one, as it is invalid.

    August 24th, 2010 @ 05:05 PM

  3. José Valim
    José Valim
    • State changed from new to invalid
    • Importance changed from to Low

    Ok, thanks Stephen!

    August 24th, 2010 @ 05:06 PM

  4. Alexander S.
    Alexander S.

    Was just about to file this bug report, but Stephen was a step ahead. Great that you'll file it.

    August 24th, 2010 @ 07:23 PM

  5. emery
    emery

    Why is this marked invalid? size should never be used in any input.

    November 5th, 2010 @ 11:00 PM