+ 5

How to draw a vertical graphical line?

well I tried to draw a line vertically so I wrote the code as <hr height="50%"/> but still it was showing a horizontal line.one thing which I found that when i changed the value it was showing the same line for every value . please help me......

12th Oct 2017, 2:42 PM
Digvijay Mahamuni
Digvijay Mahamuni - avatar
6 ответов
+ 2
Try this <hr style="transform-origin: 0%; transform:rotate(90deg);" /> (if cant work, please add css prefixer)
12th Oct 2017, 2:55 PM
Calviղ
Calviղ - avatar
+ 3
Well, if you're trying to split two parts from each other, it's good to use borders (in your case, border-right/border-left).
12th Oct 2017, 3:12 PM
$machitgarha
$machitgarha - avatar
+ 2
thank you so much calvin
12th Oct 2017, 2:56 PM
Digvijay Mahamuni
Digvijay Mahamuni - avatar
+ 1
is there any other tag for vertical line maybe like... vr or something...?
12th Oct 2017, 2:57 PM
Digvijay Mahamuni
Digvijay Mahamuni - avatar
+ 1
There is no vr tag.
12th Oct 2017, 2:59 PM
Calviղ
Calviղ - avatar
+ 1
Unfortunately, border is not a good choice when you want to put space between a vertical line. In this case, a rotated <hr/> (as Calvin mentioned), a new custom element using JS document.createElement() (e.g. <vr>) or a <div> with a special class (attribute) may be useful.
12th Oct 2017, 3:30 PM
$machitgarha
$machitgarha - avatar