Easy Tutorial
❮ Coll Form Elements Event Shiftkey ❯

Style outlineStyle Property


Definition and Usage

The outlineStyle property sets or returns the style of the outline around an element.

Syntax

Set the outlineStyle property:

Return the outlineStyle property:

Value Description
none Default. Defines no outline.
hidden The outline is closed.
dotted Defines a dotted outline.
dashed Defines a dashed outline.
solid Defines a solid outline.
double Defines a double outline.
groove Defines a 3D grooved outline. This effect depends on the outline-color value.
ridge Defines a 3D ridged outline. The effect depends on the border-color value.
inset Defines a 3D inset outline. The effect depends on the border-color value.
outset Defines a 3D outset outline. The effect depends on the border-color value.
inherit The outline style is inherited from the parent element.

Browser Support

All major browsers support the outlineStyle property.

Note: IE7 and earlier versions do not support the outlineStyle property. IE8 only supports outlineStyle if !DOCTYPE is specified. IE9 supports the outlineStyle property.


Tips and Notes

The outline is a line around the element. It is displayed around the element's margin. However, it is different from the border property.

The outline is not part of the element's dimensions, so the element's width and height properties do not include the width of the outline.


Example

Change the style of the outline:


❮ Coll Form Elements Event Shiftkey ❯