How to make a vertical line in HTML

Gopal picture Gopal · Jun 30, 2010 · Viewed 1M times · Source

How do you make a vertical line using HTML?

Answer

Kris van der Mast picture Kris van der Mast · Jun 30, 2010

Put a <div> around the markup where you want the line to appear to next, and use CSS to style it:

.verticalLine {
  border-left: thick solid #ff0000;
}
<div class="verticalLine">
  some other content
</div>