CSS border-bottom property
Example
Set the bottom border style:
p
{
border-style:
solid
;
border-bottom:
thick
dotted
#ff0000
;
}
Try it »
Tag Definition and Usage Notes
The border-bottom shorthand property sets all bottom border properties in a single declaration.
The properties that can be set are (in order): border-bottom-width, border-bottom-style, and border-bottom-color.
It is fine if one of the above values is missing, for example border-bottom: #FF0000; is allowed
| Default value: | not specified |
|---|---|
| Inherited: | no |
| Version: | CSS1 |
| JavaScript syntax: | object object.style.borderBottom="3px solid blue" |
Browser support
The numbers in the table indicate the first browser version that supports this property.
| property | |||||
|---|---|---|---|---|---|
| border-bottom | 1.0 | 4.0 | 1.0 | 1.0 | 3.5 |
Attribute values
| Value | Description |
|---|---|
| border-bottom-width | Specifies the bottom border width |
| border-bottom-style | Specifies the bottom border style |
| border-bottom-color | Specifies the bottom border color |
| inherit | Specifies that the border-bottom property value should be inherited from the parent element |
Related Articles
CSS Tutorial: CSS Borders