Borders in CSS
- CSS border properties allow you to set the border around the HTML elements.
- We can use different properties for the border. Like border color, width, style, etc.
- Also, we can make a border corner rounded with the help of border-radius.
Basic code for Border style values
<!DOCTYPE html>
<html>
<head>
<title>Background </title>
<link rel=" shortcut icon" href=" favicon.png" >
<link rel=" stylesheet" href=" style.css" >
</head>
<body>
<p class="para"> Mallu Coder Sugu</p>
</body>
</html>
Border Style and source code :
Style | Code |
Dotted
|
.para { border-style: dotted; } |
Dashed
|
.para { border-style: dashed; } |
Solid
|
.para { border-style: solid; } |
Double
|
.para { border-style: double; } |
Groove
|
.para { border-style: groove; } |
Ridge
|
.para { border-style: ridge; } |
Inset
|
.para { border-style: inset; } |
outset
|
.para { border-style: outset; } |
None
|
.para { border-style: none; } |
Hidden
|
.para { border-style: hidden; } |
Other Border Properties:
Property | Description |
border-color: |
border-color is used to set the color of the border. |
border-radius: |
The border-radius property is used to set the radius of the border corners. |
border-style: |
The border-style property defines what type of border will be displayed. Now let's see some border-style values: |
Introduction to CSS Part-2 PDF Click here to download
Easy Pickup
- 1. CSS More Samples
- 2. CSS Malayalam Classes
- 3. CSS Malayalam Notes