June44

컨텐츠 팝업 출력 소스

· 17년 전 · 1734
본 소스는 daum 에서 해당 내역만 추출 한 것입니다..

다음사이트를 보다가 유용 한것 같아서 추출 했습니다..^^;

사용에 대한 제재는 잘 모르겠네용....;;; 문제제기시 삭제 하겠습니당~

미리보기는 링크를 이용 해주세요^^

<style type="text/css">
<!--
#dashboard { display:none; position:absolute; background:transparent; width:309px; height:0%; margin:0 0 0 0; z-index:500; word-wrap:break-word; }
#resultarea { margin:0; padding:0; }

#dashboard #resultTop { height:10px; font-size:1px; line-height:1px; }
#dashboard #resultBot { height:10px; font-size:1px; line-height:1px; }

#dashboard div.lefttop #resultTop { background:url(http://pimg.hanmail.net/blog3/tip_left_1.gif) no-repeat; }
#dashboard div.lefttop #resultarea { background:url(http://pimg.hanmail.net/blog3/tip_left_2.gif) repeat-y; padding:0 8px 0 15px; }
#dashboard div.lefttop #resultBot { background:url(http://pimg.hanmail.net/blog3/tip_left_3.gif) no-repeat; }

#dashboard div.leftbot #resultTop { background:url(http://pimg.hanmail.net/blog3/tip_left_5.gif) no-repeat; }
#dashboard div.leftbot #resultarea { background:url(http://pimg.hanmail.net/blog3/tip_left_2.gif) repeat-y; padding:0 8px 0 15px; }
#dashboard div.leftbot #resultBot { background:url(http://pimg.hanmail.net/blog3/tip_left_4.gif) no-repeat; }

#dashboard div.righttop #resultTop { background:url(http://pimg.hanmail.net/blog3/tip_right_1.gif) no-repeat; }
#dashboard div.righttop #resultarea { background:url(http://pimg.hanmail.net/blog3/tip_right_2.gif) repeat-y; padding:0 15px 0 8px; }
#dashboard div.righttop #resultBot { background:url(http://pimg.hanmail.net/blog3/tip_right_3.gif) no-repeat; }

#dashboard div.rightbot #resultTop { background:url(http://pimg.hanmail.net/blog3/tip_right_5.gif) no-repeat; }
#dashboard div.rightbot #resultarea { background:url(http://pimg.hanmail.net/blog3/tip_right_2.gif) repeat-y; padding:0 15px 0 8px; }
#dashboard div.rightbot #resultBot { background:url(http://pimg.hanmail.net/blog3/tip_right_4.gif) no-repeat; }

#dashboard div.previewCotent { line-height:1.3; }
#dashboard div.previewCotent div.thumbArea { position:relative; float:right; margin:0 0 0 5px; }
#dashboard div.previewCotent div.dateArea { padding-top:4px; }
#dashboard div.previewCotent img.iconMovie { position:absolute; left:3px; top:60px; }
-->
</style>
<div id="dashboard" class=cont_text>
    <div id="resultBox" class="lefttop"><div id="resultTop"></div><div id="resultarea"></div><div id="resultBot"></div></div>
</div>
<Script language="JavaScript">
<!--
/* Layer Show/Hide */

function showPostLayer(oAnchor, sCntsId, event) {
    var oResultDiv = document.getElementById('resultarea');
    oResultDiv.innerHTML = (document.getElementById(sCntsId)? document.getElementById(sCntsId).innerHTML : "");
    
    if(oAnchor == null) return;
    var position = getPosition(oAnchor);
    var nAncX = position.x;
    var nAncY = position.y;
    var nAncWidth = oAnchor.offsetWidth;
    var nAncHeight = oAnchor.offsetHeight;

    var nDocX =  (document.documentElement.clientWidth || document.body.clientWidth);
    var nDocY = (document.documentElement.scrollHeight || document.body.scrollHeight);

    var oDashBoard = document.getElementById("dashboard");
    oDashBoard.style.display = "block";


    var nDashX = nAncX;
    var nDashY = nAncY;
    var nCntsHeight = oResultDiv.offsetHeight;
    var oResultBox = document.getElementById('resultBox');
    if(nAncX > nDocX/2) { //right
        nDashX -= 309 + 3;
        if(nAncY > nDocY - 200) { //예상 bot
            nDashY -= nCntsHeight + Math.ceil(nAncHeight/2);
            oResultBox.className = "rightbot";
        } else { //top
            nDashY += Math.ceil(nAncHeight/2);
            oResultBox.className = "righttop";
        }
    } else { //left
        nDashX += nAncWidth + 3;
        if(nAncY > nDocY - 200) { //예상 bot
            nDashY -= nCntsHeight + Math.ceil(nAncHeight/2);
            oResultBox.className = "leftbot";
        } else { //top
            nDashY += Math.ceil(nAncHeight/2);
            oResultBox.className = "lefttop";
        }
    }
    
    oDashBoard.style.left = (nDashX) + "px";
    oDashBoard.style.top = (nDashY) + "px";
}
    
function showDashBoard(){
    var obj = document.getElementById("dashboard");
    obj.style.display="block";
    viewLayer = true;
}

function hideDashBoard(){
    var obj = document.getElementById("dashboard");
    obj.style.display="none";
    viewLayer = false;
}

function getPosition(object) {
  var valueT = 0, valueL = 0;
    do {
      valueT += object.offsetTop  || 0;
      valueL += object.offsetLeft || 0;
      object = object.offsetParent;
      if (object) {
        if(object.tagName.toUpperCase()=='BODY') break;
      }
    } while (object);
    return {x: valueL, y:valueT};
}
-->
</Script>
<table width="250" align="center" border="1"><Tr><Td onclick="showPostLayer(this,'source_1',event)" onmouseout="hideDashBoard();">여기를 마우스로 클릭해 보세요^^</Td></tr></table>
<div id="source_1" style="display:none">
레이어 팝업 내용~^^
</div>
[이 게시물은 관리자님에 의해 2011-10-31 17:16:08 PHP & HTML에서 이동 됨]
|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
17년 전 조회 1,759
17년 전 조회 1,465
17년 전 조회 1,321
17년 전 조회 1,997
17년 전 조회 2,892
17년 전 조회 2,509
17년 전 조회 1,533
17년 전 조회 2,881
17년 전 조회 2,415
17년 전 조회 2,762
17년 전 조회 2,776
17년 전 조회 2,553
17년 전 조회 2,373
17년 전 조회 1,723
17년 전 조회 2,462
17년 전 조회 3,956
17년 전 조회 1,830
17년 전 조회 3,916
17년 전 조회 1,848
17년 전 조회 1,737
17년 전 조회 2,076
17년 전 조회 2,478
17년 전 조회 1,435
17년 전 조회 1,780
17년 전 조회 2,341
17년 전 조회 1,812
17년 전 조회 1,760
17년 전 조회 1,547
17년 전 조회 1,394
17년 전 조회 1,349
17년 전 조회 1,159
17년 전 조회 1,155
17년 전 조회 1,180
17년 전 조회 1,185
17년 전 조회 1,608
17년 전 조회 1,682
17년 전 조회 1,823
17년 전 조회 2,957
17년 전 조회 2,099
17년 전 조회 1,773
17년 전 조회 2,108
17년 전 조회 1,821
17년 전 조회 3,358
17년 전 조회 1,536
17년 전 조회 1,661
17년 전 조회 1,377
17년 전 조회 2,191
17년 전 조회 3,137
17년 전 조회 2,278
17년 전 조회 1,735
17년 전 조회 2,989
17년 전 조회 4,436
17년 전 조회 1,749
17년 전 조회 3,246
17년 전 조회 1,571
17년 전 조회 3,486
17년 전 조회 5,843
17년 전 조회 1,425
17년 전 조회 2,163
17년 전 조회 1,791
17년 전 조회 1,533
17년 전 조회 2,419
17년 전 조회 2,632
17년 전 조회 1,594
17년 전 조회 2,687
17년 전 조회 3,174
17년 전 조회 1,529
17년 전 조회 1,944
17년 전 조회 3,847
17년 전 조회 4,479
17년 전 조회 1,872
17년 전 조회 1,734
17년 전 조회 2,672
17년 전 조회 1,854
17년 전 조회 3,938
17년 전 조회 1,647
16년 전 조회 1,931
18년 전 조회 2,263
18년 전 조회 2,114
18년 전 조회 3,569
18년 전 조회 1,587
18년 전 조회 2,658
18년 전 조회 1,641
18년 전 조회 1,909
18년 전 조회 7,430
18년 전 조회 1,998
18년 전 조회 4,094
18년 전 조회 2,425
18년 전 조회 2,434
18년 전 조회 2,155
18년 전 조회 2,196
18년 전 조회 2,621
18년 전 조회 3,218
18년 전 조회 5,329
18년 전 조회 2,783
18년 전 조회 2,701
18년 전 조회 2,551
18년 전 조회 1,800
18년 전 조회 2,205
18년 전 조회 5,315
🐛 버그신고