placeholder
textarea - A hint to the user of what can be entered in the control. Carriage returns or line-feeds within the placeholder text must be treated as line breaks when rendering the hint. input - A hint to the user of what can be entered in the control . The placeholder text must not contain carriage returns or line-feeds.
Note: Do not use the placeholder
attribute instead of a <label>
element, their purposes are different. The <label>
attribute describes the role of the form element (i.e. it indicates what kind of information is expected), and the placeholder
attribute is a hint about the format that the content should take. There are cases in which the placeholder
attribute is never displayed to the user, so the form must be understandable without it.
Attributes
- Graph
- Supertypes
- trait Attrclass Objecttrait Matchableclass Any
- Self type
- placeholder.type