IT, 프로그래밍/HTML, CSS

부트스트랩 가운데 정렬

오리@ 2018. 7. 26. 11:04


class에 text-center / style에 float:none; margin:0 auto를 추가한다


1
2
3
4
5
6
7
8
9
10
    <div class="row text-center" style="width: 100%">
 
                    <div style="width: 30%; float:none; margin:0 auto" >
                            <button class="btn btn btn-danger btn-round" style="width: 100%">더보기</button>
 
                            <div>
                            </div>
                    </div>
    </div>
 
cs





---------------------- 정가운데 정렬


style태그에 밑을 선언


 display:flex;
  align-items:center;