D
D
dhat2016-09-15 11:59:10
css
dhat, 2016-09-15 11:59:10

How to vertically center .div in Bootstrap?

How to vertically center a black and yellow .div inside a red one? I can't find how to do this in Bootstrap. Do you need to write your own class? What is the best way to do this without breaking anything in Bootstrap (surely there is some best practice)?
codepen.io/dhatt/pen/KgzoGx

Answer the question

In order to leave comments, you need to log in

2 answer(s)
C
Cyber_bober, 2016-09-15
@dhat

codepen.io/cyberbober/pen/dprmAp

R
Raz-Dva, 2016-09-15
@Raz-Dva

In my opinion, you can’t align vertically through classes in bootstrap. You need to set the css yourself.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question