채택완료

부트스트랩 모달팝업 사용중인데요 백그라운드 문제

2021-04-23 (금) 12:14:37 2,293

237481359_1619147420.7135.png

지금 이런식으로 백그라운드가 위에 뜨네요

css도 부트스트랩 그냥 불러와서 쓰는데

z-index가 아예안먹습니다.

원페이지 형태의 사이트라서 모달 위치값에 transform: translateY(100%);를 주었는데요ㅠ

Copy
.section2 .content_l{height:100%; position:relative; z-index:9999999999}
.section2 .content_l .row{height:100%; padding:0; margin:0; text-align:center;}
.section2 .content_l .row > div{overflow: hidden;}
.section2 .content_l .row > div:after{display:inline-block; height:100%; content:""; vertical-align:middle;}
.section2 .content_l .row > div > a >img{vertical-align:middle; width:95%; max-width:362px;}
.section2 .content_l .row .c1{background:url(/img/main2_bg_02.jpg) no-repeat center;}
.section2 .content_l .row .c2{background:url(/img/main2_bg_03.jpg) no-repeat center;}
.section2 .content_l .row .c3{background:url(/img/main2_bg_04.jpg) no-repeat center;}

팝업이 총 3개라서 이렇게 주었구요.

Copy
.modal{transform: translateY(100%); -webkit-transform: translateY(100%); z-index:1060 !important;}
.modal-backdrop{z-index:1 !important;}

추가 css 입력했습니다.

부트스트랩에서

<div class="modal-backdrop fade show"></div>

이배경을 자동으로 불러와서 바디 최하단에 쌓이구요..ㅠ

어케해야할까요ㅠ

|

답변 1개

채택된 답변
+20 포인트
2021-04-23 (금) 19:23:49

부트스트랩 주소로 불러오시나요?? 아니면 파일로 불러오시나요?? 부트스트랩 모달 css 부분에 z-index 수정하시면 되실거에요~~

답변을 작성하려면 로그인이 필요합니다.