X
HOME HTML5 CSS3 JAVASCRIPT SQL PHP5 JQUERY ANGULAR BOOTSTRAP3 XML MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

Style columnRule Property

Style Object Reference Style Object

Example

Specify the width, style and color of the rule between columns:

document.getElementById("myDIV").style.columnRule = "3px outset blue";

Try it yourself »


Definition and Usage

The columnRule property is a shorthand property for setting all the columnRule* properties.

The columnRule property sets the width, style, and color of the rule between columns.


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The columnRule property is supported in Internet Explorer 10 and Opera.

Firefox supports an alternative, the MozColumnRule property.

Safari and Chrome support an alternative, the WebkitColumnRule property.


Syntax

Return the columnRule property:

object.style.columnRule

Set the columnRule property:

object.style.columnRule="column-rule-width column-rule-style column-rule-color|initial|inherit"

Property Values

Value Description
columnRuleWidth Sets the width of the rule between columns. Default value is medium
columnRuleStyle Sets the style of the rule between columns. Default value is none
columnRuleColor Sets the color of the rule between columns. Default value is the color of the element
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit

Technical Details

Default Value: medium none color
Return Value: A String, representing the column-rule property of an element
CSS Version CSS3


Related Pages

CSS3 tutorial: CSS3 Multiple Columns

CSS reference: column-rule property


Style Object Reference Style Object

Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB HOSTING

UK Reseller Hosting

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates

SHARE THIS PAGE

facebook