따라다니는게 아니라 항상 제일 하단에 스티커처럼 고정되어 있는것처럼 할려면 어떻게 해야하나요?
참고로 경향신문 모바일입니다.
<script type="text/javascript">
var adObj = document.createElement("DIV");
adObj.id="dualad_div34";
adObj.style.zindex="999";
adObj.style.position="absolute";
adObj.style.bottom="0px";
adObj.style.left="0px";
adObj.style.width="100%";
adObj.style.height="50px";
document.body.appendChild(adObj);
var adObj = document.createElement("DIV");
adObj.id="dualad_div34";
adObj.style.zindex="999";
adObj.style.position="absolute";
adObj.style.bottom="0px";
adObj.style.left="0px";
adObj.style.width="100%";
adObj.style.height="50px";
document.body.appendChild(adObj);
var daum_adam_vars = {
position : 'MIDDLE', // TOP (화면상단) | BOTTOM (화면 하단) | MIDDLE (화면 중간 삽입. bannerDivId 지정 필요)
bannerDivId : 'dualad_div34', // position : 'MIDDLE' 인 경우, 광고를 삽입할 DIV 테그의 ID 값.
};
position : 'MIDDLE', // TOP (화면상단) | BOTTOM (화면 하단) | MIDDLE (화면 중간 삽입. bannerDivId 지정 필요)
bannerDivId : 'dualad_div34', // position : 'MIDDLE' 인 경우, 광고를 삽입할 DIV 테그의 ID 값.
};
function setAdPosition(target, position, topLimit, btmLimit) {
if (!target) return false;
var obj = target;
obj.initTop = position;
obj.topLimit = topLimit;
obj.bottomLimit = Math.max(document.documentElement.scrollHeight, document.body.scrollHeight) - btmLimit - obj.offsetHeight;
obj.style.position = "absolute";
obj.top = obj.initTop;
obj.left = obj.initLeft;
if (typeof (window.pageYOffset) == "number") {
obj.getTop = function () {
return window.pageYOffset;
}
} else if (typeof (document.documentElement.scrollTop) == "number") {
obj.getTop = function () {
return Math.max(document.documentElement.scrollTop, document.body.scrollTop);
}
} else {
obj.getTop = function () {
return 0;
}
}
if (self.innerHeight) {
obj.getHeight = function () {
return self.innerHeight;
}
} else if (document.documentElement.clientHeight) {
obj.getHeight = function () {
return document.documentElement.clientHeight;
}
} else {
obj.getHeight = function () {
return 500;
}
}
if (obj.initTop > 0) {
pos = obj.getTop() + obj.initTop;
} else {
pos = obj.getTop() + obj.getHeight() + obj.initTop;
}
if (pos > obj.bottomLimit) pos = obj.bottomLimit;
if (pos < obj.topLimit) pos = obj.topLimit;
obj.style.top = (obj.top + pos) + "px";
}
if (!target) return false;
var obj = target;
obj.initTop = position;
obj.topLimit = topLimit;
obj.bottomLimit = Math.max(document.documentElement.scrollHeight, document.body.scrollHeight) - btmLimit - obj.offsetHeight;
obj.style.position = "absolute";
obj.top = obj.initTop;
obj.left = obj.initLeft;
if (typeof (window.pageYOffset) == "number") {
obj.getTop = function () {
return window.pageYOffset;
}
} else if (typeof (document.documentElement.scrollTop) == "number") {
obj.getTop = function () {
return Math.max(document.documentElement.scrollTop, document.body.scrollTop);
}
} else {
obj.getTop = function () {
return 0;
}
}
if (self.innerHeight) {
obj.getHeight = function () {
return self.innerHeight;
}
} else if (document.documentElement.clientHeight) {
obj.getHeight = function () {
return document.documentElement.clientHeight;
}
} else {
obj.getHeight = function () {
return 500;
}
}
if (obj.initTop > 0) {
pos = obj.getTop() + obj.initTop;
} else {
pos = obj.getTop() + obj.getHeight() + obj.initTop;
}
if (pos > obj.bottomLimit) pos = obj.bottomLimit;
if (pos < obj.topLimit) pos = obj.topLimit;
obj.style.top = (obj.top + pos) + "px";
}
document.body.addEventListener('touchstart', function (e) {
var evt = e || window.event;
var target = evt.target || evt.srcElement;
var node = target.parentNode;
var hide = true;
while (node) {
if (node.id === daum_adam_vars.bannerDivId) {
hide = false;
break;
}
node = node.parentNode;
}
if (hide) {
document.getElementById('dualad_div34').style.display = 'none';
}
}, false);
window.addEventListener('scroll', function () {
setAdPosition(document.getElementById("dualad_div34"), - 30, 0, - 30);
document.getElementById('dualad_div34').style.display = 'block';
}, false);
var evt = e || window.event;
var target = evt.target || evt.srcElement;
var node = target.parentNode;
var hide = true;
while (node) {
if (node.id === daum_adam_vars.bannerDivId) {
hide = false;
break;
}
node = node.parentNode;
}
if (hide) {
document.getElementById('dualad_div34').style.display = 'none';
}
}, false);
window.addEventListener('scroll', function () {
setAdPosition(document.getElementById("dualad_div34"), - 30, 0, - 30);
document.getElementById('dualad_div34').style.display = 'block';
}, false);
window.addEventListener('load', function() {
if (navigator.userAgent.indexOf('Safari')!=-1){
setTimeout(scrollTo,0,0,1);
}else{
window.scrollTo(0,1);
}
setTimeout("setAdPosition(document.getElementById('dualad_div34'), -24, 0, -24)",1);
}, false);
</script>
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 6130 |
gender
|
12년 전 | 1095 | |
| 6129 | 12년 전 | 1322 | ||
| 6128 |
|
12년 전 | 3463 | |
| 6127 | 12년 전 | 696 | ||
| 6126 |
|
12년 전 | 2208 | |
| 6125 |
|
12년 전 | 4886 | |
| 6124 | 12년 전 | 661 | ||
| 6123 | 12년 전 | 3843 | ||
| 6122 | 12년 전 | 1018 | ||
| 6121 | 12년 전 | 3751 | ||
| 6120 | 12년 전 | 909 | ||
| 6119 | 12년 전 | 1770 | ||
| 6118 | 12년 전 | 931 | ||
| 6117 | 12년 전 | 2150 | ||
| 6116 | 12년 전 | 7942 | ||
| 6115 | 12년 전 | 1920 | ||
| 6114 |
|
12년 전 | 1708 | |
| 6113 | 12년 전 | 1525 | ||
| 6112 | 12년 전 | 595 | ||
| 6111 | 12년 전 | 2111 | ||
| 6110 | 12년 전 | 1850 | ||
| 6109 | 12년 전 | 642 | ||
| 6108 | 12년 전 | 1200 | ||
| 6107 | 12년 전 | 624 | ||
| 6106 | 12년 전 | 906 | ||
| 6105 | 12년 전 | 1192 | ||
| 6104 | 12년 전 | 3596 | ||
| 6103 | 12년 전 | 2124 | ||
| 6102 | 12년 전 | 2315 | ||
| 6101 | 12년 전 | 3677 | ||
| 6100 | 12년 전 | 3484 | ||
| 6099 | 12년 전 | 3155 | ||
| 6098 | 12년 전 | 4026 | ||
| 6097 | 12년 전 | 1016 | ||
| 6096 | 12년 전 | 5985 | ||
| 6095 | 12년 전 | 1370 | ||
| 6094 | 12년 전 | 1225 | ||
| 6093 | 12년 전 | 3408 | ||
| 6092 | 12년 전 | 3053 | ||
| 6091 | 12년 전 | 5195 | ||
| 6090 | 12년 전 | 2705 | ||
| 6089 | 12년 전 | 3326 | ||
| 6088 | 12년 전 | 1016 | ||
| 6087 | 12년 전 | 848 | ||
| 6086 | 12년 전 | 2019 | ||
| 6085 |
|
12년 전 | 806 | |
| 6084 |
웹디자인되고파
|
12년 전 | 2219 | |
| 6083 | 12년 전 | 1508 | ||
| 6082 | 12년 전 | 1111 | ||
| 6081 | 12년 전 | 2099 | ||
| 6080 |
Stiven
|
12년 전 | 2312 | |
| 6079 |
프로프리랜서
|
12년 전 | 1322 | |
| 6078 |
프로프리랜서
|
12년 전 | 787 | |
| 6077 |
프로프리랜서
|
12년 전 | 1345 | |
| 6076 |
프로프리랜서
|
12년 전 | 832 | |
| 6075 |
프로프리랜서
|
12년 전 | 1224 | |
| 6074 | 12년 전 | 3855 | ||
| 6073 | 12년 전 | 3949 | ||
| 6072 | 12년 전 | 1377 | ||
| 6071 | 12년 전 | 6992 | ||
| 6070 | 12년 전 | 7574 | ||
| 6069 | 12년 전 | 2320 | ||
| 6068 | 12년 전 | 3868 | ||
| 6067 |
smwkd
|
12년 전 | 633 | |
| 6066 | 12년 전 | 3658 | ||
| 6065 | 12년 전 | 3486 | ||
| 6064 | 12년 전 | 2720 | ||
| 6063 | 12년 전 | 2841 | ||
| 6062 | 12년 전 | 2372 | ||
| 6061 | 12년 전 | 2279 | ||
| 6060 | 12년 전 | 5185 | ||
| 6059 | 12년 전 | 2815 | ||
| 6058 | 12년 전 | 3136 | ||
| 6057 | 12년 전 | 2262 | ||
| 6056 | 12년 전 | 6842 | ||
| 6055 | 12년 전 | 2581 | ||
| 6054 | 12년 전 | 3435 | ||
| 6053 | 12년 전 | 2328 | ||
| 6052 | 12년 전 | 4821 | ||
| 6051 | 12년 전 | 3712 | ||
| 6050 | 12년 전 | 2555 | ||
| 6049 | 12년 전 | 2245 | ||
| 6048 |
|
12년 전 | 1300 | |
| 6047 | 12년 전 | 3441 | ||
| 6046 | 12년 전 | 4096 | ||
| 6045 | 12년 전 | 3456 | ||
| 6044 | 12년 전 | 5331 | ||
| 6043 | 12년 전 | 1652 | ||
| 6042 | 12년 전 | 1282 | ||
| 6041 | 12년 전 | 5165 | ||
| 6040 | 12년 전 | 939 | ||
| 6039 | 12년 전 | 3413 | ||
| 6038 | 12년 전 | 3414 | ||
| 6037 | 12년 전 | 2993 | ||
| 6036 | 12년 전 | 3341 | ||
| 6035 | 12년 전 | 2867 | ||
| 6034 | 12년 전 | 2846 | ||
| 6033 | 12년 전 | 2867 | ||
| 6032 | 12년 전 | 2854 | ||
| 6031 | 12년 전 | 2881 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기