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:
<code>border-color: <color-value> [ <color-value> <color-value> <color-value> ];</code>
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.
<code class="css">border-color: #FF0000;</code>
Multiple border colors: Set the colors of different borders, in clockwise order: top border, right border, bottom border, left border.
<code class="css">border-color: #FF0000 #00FF00 #0000FF #FFFF00;</code>
Example:
<code class="html"><div style="border-color: red;">...</div></code>
Output:
A div with a red border.<code class="html"><div style="border-color: red green blue yellow;">...</div></code>
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!