border

The border property is a shorthand property for setting the same width, color, and style for all four borders of a box.

Syntax

border: [ <border-width> || <border-style> || <'border-top-color'> ] | inherit
Initial: medium, none, value of the color property
Applies To: all elements
Inherited: no
Percentages: NA
Media: visual

DOM

[window.]document.getElementById("element-id").style.border = "border-color border-style border-width";

Example | color | color

Example | color | transparent

Example | style | dashed

Example | style | dotted

Example | style | double

Example | style | groove

Example | style | hidden

Example | style | inset

Example | style | none

Example | style | outset

Example | style | ridge

Example | style | solid

Example | width | length

Example | width | medium

Example | width | thick

Example | width | thin

Example | DOM

External

W3C Cascading Style Sheets, level 1

W3C Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification

W3C CSS Backgrounds and Borders Module Level 3