Skip to content

[Form] read_only field option should create a readonly input attribute #1974

Closed
@kmohrf

Description

@kmohrf

hey,

i stumbled upon this field option and think it's not the right way to solve it

http://symfony.com/doc/current/reference/forms/types/text.html#read-only

the docs say, that the read_only parameter renders the field with a disabled attribute. even if disabled is the favored method of setting the field "not-editable" the parameter should be called disabled because there actually is a readonly attribute since html4 and it allows some kind of interaction that a disabled field does not.

in my case i have a text input that is filled with a value by a colorpicker. the color picker is triggered by the user clicking on that field. in contrast to a readonly input a disabled input is not clickable.

this is not a blocker as the readonly attribute can still be created by adding it to the attr parameter. i guess its still confusing though.

kind regards (and thanks for creating this)

konrad

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions