Select Chapter ❯
CSS Tutorial
- CSS Introduction
- CSS Syntax
- CSS Insert CSS
- CSS Backgrounds
- CSS Text
- CSS Dimensions
- CSS Border
- CSS Margin
- CSS Padding
- CSS Display
- CSS Positioning
- CSS Float
- CSS Pseudo-Class
- CSS Opacity
- CSS Media Types
CSS3 Tutorial
CSS Border
CSS Border and other border properties is used to set and style the border for elements.
CSS Border Properties are as follows
- Border:CSS border property is used to set border to an element.You can set the border individually to a single side.
- Border Style:CSS border-style property is used to set style to the borders of an element.You can set the border-style individually to a single side.
- border-style: dotted solid double dashed;
- border-style: dotted solid double;
- border-style: dotted solid;
- border-style: dotted;
- Border Width:CSS border-width property is used to set the width to the borders of an element.You can set the border-style individually to a single side.
- Border Color:CSS border-color property is used to set the color to the borders of an element.You can set the border-style individually to a single side.
- Border Collapse:CSS border-color property is used to set whether the table borders are seperated or collapsed into a single border.Two possible values of border-collapse either collapse or seperated.
- border:Sets all the border properties
- border-top:Sets all the top border properties
- border-left:Sets all the left border properties
- border-bottom:Sets all the bottom border properties
- border-right:Sets all the right border properties
- border-color:Sets the color of the four borders
- border-top-color:Sets the color of the top border
- border-left-color:Sets the color of the left border
- border-bottom-color:Sets the color of the bottom border
- border-right-color:Sets the color of the right border
- border-style:Sets the style of the four borders
- border-top-style:Sets the style of the top border
- border-left-style:Sets the style of the left border
- border-right-style:Sets the style of the right border
- border-bottom-style:Sets the style of the bottom border
- border-widthSets the width of the four borders
- border-top-widthSets the width of the top border
- border-left-width:Sets the width of the left border
- border-bottom-width:Sets the width of the bottom border
- border-right-width:Sets the width of the right border
div { border:1px solid blue; }
div { border-style:dotted solid double dashed; }
border-style values.
top border is dotted.
right border is solid.
bottom border is double.
left border is dashed.
top border is dotted.
right and left borders are solid.
bottom border is double.
top and bottom borders are dotted.
right and left borders are solid.
all four borders are dotted.
div { border-width:10px; }
div { border-color:red; }
div { border-collapse:collapse; }
All CSS Border Properties