From Web Education Community Group
< CSS‎ | Properties
Revision as of 11:25, 20 November 2011 by Rworth (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search


The border-color property is a shorthand property for setting 'border-top-color', 'border-right-color', 'border-bottom-color', and 'border-left-color' at the same place in the style sheet.


Values [ <color> | transparent ]{1,4} | inherit
Initial value See individual properties
Applies to all elements
Inherited No


  • [ <color> | transparent ]{1,4}

  • inherit
    Takes the same specified value as the property for the element's parent.

And see also individual properties


Example A


 h1 {
   border-width: 1px;
   border-style: solid;
   border-color: red black


    <h1>CSS border property example</h1>

Csslist2 border-color.png

CSS Reference

The CSS specification defines the border-color property in 8.5.2 Border color.

See also