백그라운드 관련질문드립니다.
여름
안녕하세요!
사이트 메인 따라하는데 막힙니다.
초짜 질문드립니다.
바디에 style=background: url(...) no-repeat center 100px; 이런식으로 백그라운드를 깔았습니다.(4500_525사이즈의 이미지)
파폭에선 보이는데 익스에서 보이지 않는 이유를 모르겠습니다.
고수님들의 답변 부탁합니다.
그리고 margin 값과 overflow관련 질문인데요 아래 빨깐 텍스트부분 보시면
!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
html xmlns=http://www.w3.org/1999/xhtml xml:lang=ko lang=ko
head
style type=text/css
--
html,body{width:100%;height:100%;}
body{background: url(images/main_bg.jpg)no-repeat center 100px;font-size:12px;}
*{padding:0;margin:0;}
ol,ul,li,p{list-style:none;}
img{border:0;}
#wrap{width:980px;height:auto;position:relative;margin:0 auto;background-color:;overflow:hidden;}
요기overflow:hidden;써주니 파폭에높이 값을 가지고 익스에선 안해줘도 가지던데 이유를 모르겠어요
.logo{float:left;padding:27px 0 16px 0;}
#contents{width:100%;margin:525px auto;clear:both;background-color:;}
요기 마진값을 525px를 주니 gogo라는 글씨가 파폭에선 100px모자란 425px위치에있더라구요 이유를 모르겠습니다. 백그라운가 안보이니 익스에선 제대루 위치해 있는지도 모르겠고.. (이미지 첨부를 하려하나 회사가 다 막아놔서 올리는 못합니다)
익스 ,파폭 높이값을 같게 하려면 어떻게 해야하나요?
--
/style
meta http-equiv=content-Type content=text/html; charset=euc-kr /
title타이틀/title
/HEAD
BODY
div id=wrap
div class=logo
img src=images/me_logo.jpg
/div
div id=contents
gogo
/div
/div
/BODY
/HTML
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
아래는 이차 연습 소스입니다
!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
html xmlns=http://www.w3.org/1999/xhtml xml:lang=ko lang=ko
head
style type=text/css
--
html,body{width:100%;height:100%;}
body{background: url(images/main_bg.jpg) no-repeat center 100px transparent; font-size:12px;}
*{padding:0;margin:0;}
ol,ul,li,p{list-style:none;}
img{border:0;}
#wrap{width:980px;height:auto;position:relative;margin:0 auto;background-color:;overflow:hidden;}
.logo{float:left;padding:27px 0 16px 0;}
#contents{width:100%;padding:545px 0 0 0;clear:both;background-color:;}
#contents .box1{width:250px;float:left;position:relative;border:0px solid #ddd;margin:0 70px 0 0;}
#contents .box1 h1{width:100%;height:13px;}
#contents .box1 h1 .more1{position:absolute;top:0;right:0;}
#contents .box1 .kongzi_box1{width:100%;height:auto;padding:10px 0 0 0;}
#contents .box1 .kongzi_box1 .box_first{width:100%;}
#contents .box1 .kongzi_box1 .box_first .first_big{background: url(images/main_list.gif) no-repeat 0 70%;padding:10px 0 0 8px;font-size:11px;color:#666666;font-family:dotum;position:relative;}
#contents .box1 .kongzi_box1 .box_first .first_big .first_small{color:#999999;position:absolute;right:0;}
#contents .box2{width:250px;float:left;position:relative;border:0px solid #ddd;}
#contents .box2 h1{width:100%;height:13px;}
#contents .box2 h1 .more1{position:absolute;top:0;right:0;}
#contents .box2 .kongzi_box1{width:100%;height:auto;padding:10px 0 0 0;}
#contents .box2 .kongzi_box1 .box_first{width:100%;}
#contents .box2 .kongzi_box1 .box_first .first_big{background: url(images/main_list.gif) no-repeat 0 70%;padding:10px 0 0 8px;font-size:11px;color:#666666;font-family:dotum;position:relative;}
#contents .box2 .kongzi_box1 .box_first .first_big .first_small{color:#999999;position:absolute;right:0;}
#contents .box3{width:330px;float:right;}
#contents .box3 h1{width:100%;height:13px;}
#contents .box3 .kongzi_box1{width:100%;height:auto;padding:10px 0 0 0;}
#contents .box3 .kongzi_box1 .box_first{width:100%;}
#contents .box3 .kongzi_box1 .box_first .first_big{padding:0 0 0 0;float:left;}
#contents .box3 .kongzi_box1 .box_first .first_big_1{padding:0 0 0 11px;float:left;}
--
/style
meta http-equiv=content-Type content=text/html; charset=euc-kr /
title타이틀/title
/HEAD
BODY
div id=wrap
div class=logo
img src=images/me_logo.jpg
/div
div id=contents
div class=box1
h1img src=images/main_01.gifimg src=images/main_more.gif class=more1/h1
&;
div class=kongzi_box1
ul class=box_first
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
/ul
/div
/div
div class=box2
h1img src=images/konzi.gifimg src=images/main_more.gif class=more1/h1
div class=kongzi_box1
ul class=box_first
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
li class=first_big2013년도 전문대학 기관평가인증...span class=first_small2013.02.20/span/li
/ul
/div
/div
div class=box3
h1img src=images/main_03.gif/h1
div class=kongzi_box1
ul class=box_first
li class=first_bigimg src=images/main_quick01.gif/li
li class=first_big_1img src=images/main_quick02.gif/li
li class=first_big_1img src=images/main_quick03.gif/li
li class=first_big_1img src=images/main_quick04.gif/li
/ul
/div
/div
/div
/div
/BODY
/HTML
-
유린
헉 그런가요?
마진값을 줘도 익스랑 파폭에서도 같은 위치를 갔는다는 이야기죠? 저는 계속 안되고 있어요 ㅠㅠ -
공주
음 높이 같게 나오는데요?
-
걸때
우선 감사드립니다. 백그라운드는 한칸 띄우니 익스에서도 잘보이네요 ^^
패딩을 쓰면 얼추 위치는 잡히는데...마진을 쓰면 gogo위치가 제대루 안나오네요..마진을 썼을때 위치가 제대루 잡히는 방법을 알고 싶습니다.제가 본 사이트에서는마진을 썼더라구요 그리고 #wrap부분 overflow:hidden의 역할도 알고싶습니다.
아그리고 초기화 부분은 *{margin:0;padding:0;}으론 안되는건가요?
초보라 질문이 두서없이 많습니다. ㅠㅠ -
둘빛
우선 body 백그라운드 css 부분에 no-repeat 앞에 한칸 띄워주시구요
#contents의 margin은 padding으로 바꿔도 되는 부분 아닌가요? css 초기화도 안되어 있으니 그거부터 하시구요.
번호 | 제 목 | 글쓴이 | 날짜 |
---|---|---|---|
2701230 | 테마 설정하면 밑에 뜨는 글 삭제 (1) | 창의적 | 2025-07-12 |
2701177 | css적용이 안되요~ (6) | 다니엘 | 2025-07-11 |
2701151 | 사이트작업시 inputbox 가 readonly 형태표시 어떻게 하시나요? (1) | 찬내 | 2025-07-11 |
2701123 | 간단한 select 질문입니다 (3) | 천사의눈물 | 2025-07-11 |
2701061 | 비베질문.. | 똘끼 | 2025-07-10 |
2701034 | 메일폼 내 script 삽입가능한 방법 없을까요.. (2) | 마음새 | 2025-07-10 |
2701008 | 분명히 버튼을 만들었는데 액션이 안걸립니다. (3) | 재찬 | 2025-07-10 |
2700923 | 전체중앙정렬&독타입&쿼크모드 ㅜㅠ (8) | 푸른들 | 2025-07-09 |
2700893 | 질문드리겠습니다. | 도도한 | 2025-07-09 |
2700793 | 무비클립에 마우스 오버시 랜덤으로 효과음 나기는 어떻게 ;; (1) | 바닐라 | 2025-07-08 |
2700741 | 웹전송? (2) | 연와인 | 2025-07-07 |
2700686 | 카테고리 호버시 세부카테고리 보이게하는 것, css로만 가능할까요?? (3) | 다힘 | 2025-07-07 |
2700658 | 메타태그 질문드립니다..ㅠㅠ;;; | 모해 | 2025-07-07 |
2700632 | 외부에서 이미지 파일을 불러와야 합니다. 도와주세요. (4) | 에일린 | 2025-07-06 |
2700579 | (air + as3) smtp 이용해서 첨부파일 포함해서 메일 보내기 | 물보라 | 2025-07-06 |
2700524 | 클릭시 밑에 메뉴 나오게 (4) | 새솔 | 2025-07-05 |
2700505 | activex를 비쥬얼6.0으로 만들었는데요 비스타 배포시에 안되서 질문드립니다 (3) | 참이 | 2025-07-05 |
2700452 | c언어에서... 자료형 구분.... (3) | 시내 | 2025-07-05 |
2700422 | 버전에 관해 질문 | 라온제나 | 2025-07-04 |
2700393 | mysql이 갑자기!!!!!!!!!!!!!!!에러가;; (2) | 소미 | 2025-07-04 |