How to Create Vertical and Horizontal Line in HTML CSS

Amit Kumar
May 10, 2022

--

Lets go to start how to create vertical line.

This is css part

.my-testing-dashed {
position: relative;
font-size: 2.15em;
line-height: 40px;
font-weight: 700;
color: #1c539e;
}

.my-testing-dashed:after {
content: "";
width: 64px;
border-bottom: 5px solid orangered;
display: block;
padding-bottom: 15px;
}

Next go to index.html and paste this code

<h4 class="my-testing-dashed mt-5">Make more profit from your distribution business. <br>One-time investment, lifetime returns</h4>

2nd vertical line

This is css

.vrline {
border-left: 4px solid #fc4a1a;
line-height: 133%;
padding-left: 2%;
}

this is index.html

<h4 class="vrline">Partner's Benefits</h4>

OUTPUT:-

2nd OUPUT

--

--

Amit Kumar

Hi I am Amit Experienced Web Developer with a demonstrated history of working in the information technology and services industry.