One, dashed line and solid border
Border Dash style:dashed
Border implementation style:solid
border:1px Dashed #000
Represents set object border width 1px black dashed border
BORDER:1PX Solid #000
Represents the Set object border width 1px black implementation border
Second, the top of the div and border
We'll add a 1px black border to the top of the Div.
- div{border-top:1px Solid #000}
Third, add a border to the bottom of Div
Add a 2px dashed red border to the bottom of the div box
- div{border-bottom:2px Dashed #F00}
Iv. add a border to the left of the Div box
Name a CSS selector css named ". Divcss5" box to the left with a blue 1px solid line border
- . divcss5{border-left:1px Solid #00F}
div Code:
- <div class="DIVCSS5"> The left side of this div box is a 1px solid line blue border </div>
Add a border to the right of the box div
Add 1px red solid border to the right of the Div object
- div{border-right:1px Solid #F00}
Six, the box up and down the border
Add 1px to the box to achieve a black border
- div{border-top:1px solid #000; border-bottom:1px Solid #000}
Seven, give div box left and right border
Add 2px dashed green border around box
- div{border-left:2px dashed #0F0; border-right:2px dashed #0F0}
Eight, give div four sides plus a border
Give a div four sides plus 3px to implement a black border
- div{border:3px Solid #000}
Div Plus Border