border

Description »

This property is shorthand for setting the main border properties of an element, including width, style, and color.

Browser Compatibility
IE FF GC S O

Possible Values »

  • border: width style color;
  • Sets the standard width, style, and color of an element's borders.
  • border: none;
  • Sets an element to have no borders
  • border: inherit;
  • Inherits border values from parent element.

Details »

This single property name combines three main border properties for convenience:

This property will set all four borders of an element. To set individual borders (such as only the bottom border), append the border property with the specified side:

In Practice »

Results CSS
Try it! at The CSS Zone Sandbox
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License