Home>Article>Daily Programming> How to use the bordercolor attribute of css
CSS border-color property purpose: Set the color of the element border. Syntax: border-color: [color value] [color value] [color value] [color value] Single border color: Set all borders to the same color. Multiple border colors: the order is: top, right, bottom, left, different colors can be specified.
CSS border-color property
Usage:
border The -color attribute is used to set the color of the element's border.
Syntax:
border-color: [ ];
Parameters:
##
: Valid CSS color value, for example:
)
)
)
,
blue)
Usage:
border-color attribute can be set Single or multiple border colors, the specific usage is as follows:Single border color:Set the color of all borders to the same color.
border-color: #FF0000;
Multiple border colors:Set the colors of different borders, in clockwise order: top border, right border, bottom border, left border.
border-color: #FF0000 #00FF00 #0000FF #FFFF00;
Example:
...
Output:
A div with a red border....
Output:
A div with a red upper border, a green right border, a blue lower border, and a yellow left border.The above is the detailed content of How to use the bordercolor attribute of css. For more information, please follow other related articles on the PHP Chinese website!