CSS/Properties/border
From W3C Wiki
< CSS | Properties
Contents |
border
The border property is a shorthand property for setting the same width, color, and style for all four borders of a box.
Description
| Values | [ <border-width> || <border-style> || <border-color> ] | inherit |
|---|---|
| Initial value | See individual properties |
| Applies to | all elements |
| Inherited | No |
Values
inherit
Takes the same specified value as the property for the element's parent.
And see also individual properties
Example
Example A
[style.css]
h1 {
border: 1px solid red;
}
[index.html]
<body>
<h1>CSS border property example</h1>
</body>
CSS Reference
The CSS specification defines the border property in 8.5.4 Border shorthand properties.

