value property CSS Reference



Definition and Usage

A form element may contain both a label for its data value, and the data value itself. For such elements, the ::value pseudo-element selects the representation of just the data value itself, in order to style its appearance.


Syntax

element:value { style properties }

Examples

<input>
<label>Zip code<label>
<input::value/>
</input>
input { border:dashed }
label { border:dotted }
input::value { border:solid }

Relative articles