jpg 출력 궁금한점.
본문
#full_page {background:url('../img/main.jpg');no-repeat center center fixed; -webkit-background-size: cover;-moz-background-size: cover;-o-background-size: cover;background-size: cover;z-index:5;margin:0 auto;width:100%;height:100%;zoom:1} // 메인화면 출력
#sub_page{background:url('../img/mainn.jpg');no-repeat center center fixed; -webkit-background-size: cover;-moz-background-size: cover;-o-background-size: cover;background-size: cover;z-index:5;margin:0 auto;width:100%;height:200px;zoom:1} // 일반페이지 출력
일반페이지에 각각 게시판마다 다른 이미지를 넣어주고 싶은데 공지사항,자유게시판등 위에 소스로 같은 이미지가 뜨네요 다르게 이미지를 넣으려면 소스를 어떤식으로 짜야하나요?
답변 1
아래 소스를 /bbs/board_head.php 파일에 추가해주고,
이미지는 main_게시판코드.jpg 파일을 올리면 됩니다.
혹시, 적용이 안되면 !important 를 추가해주세요.
<style>
#sub_page{background:url('../img/main_<? echo $bo_table ?>.jpg');no-repeat center center fixed; -webkit-background-size: cover;-moz-background-size: cover;-o-background-size: cover;background-size: cover;z-index:5;margin:0 auto;width:100%;height:200px;zoom:1}
</style>
답변을 작성하시기 전에 로그인 해주세요.