HTML and CSS Reference
In-Depth Information
Name
border-width
Values:
[
thin
|
medium
|
thick
| <length> ]{1,4}
Initial value:
Not defined for shorthand properties
Applies to:
All elements
Inherited:
No
Computed value:
See individual properties
Description:
A shorthand property that defines the width for the overall border of an element or for each
side individually. The width will take effect for a given border only if the border's style is
something other than
none
. If the border style is
none
, the border width is effectively reset to
0
. Negative length values are not permitted.
Examples:
h1 {border-width: 2ex;}
img {border-width: 5px thick thin 1em;}