꼬옥 답변 부탁합니다. _ 레이어 팝업창 관련 정보
꼬옥 답변 부탁합니다. _ 레이어 팝업창 관련본문
팝업창 관리 1.7 설치했구요
윈도우 팝업은 문제 없습니다.
그런데 레이어 팝업만 띄우고 '00동안 이 창을 보이지 않음'에 체크하고
닫기 버튼을 누르면 아무런 반응이 없습니다.
자바스크립트 오류가 생기는 것도 아니고...
일반 게시판에 팝업을 띄우면 제대로 동작하는데 그누보드 폴더 밖에 있는 index.php 파일에
팝업을 띄우니까 그러네요.
참고로 _common 파일도 넣었습니다.
layerview.php 파일입니다.
-----------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<style>
div{
scrollbar-face-color:#eeeeee;
scrollbar-highlight-color: #ffffff;
scrollbar-3dlight-color: #ffffff;
scrollbar-shadow-color: #cccccc;
scrollbar-darkshadow-color: #999999;
scrollbar-track-color: #eeeeee;
scrollbar-arrow-color: #999999
}
#pop{id}{
position:absolute;
z-index:{zindex};
width:{po_width}px;
height:{po_height}px;
filter:alpha(opacity=100);
overflow : hidden;
}
</style>
<div id="pop{id}" >
<div style="width:{po_width}px;overflow:hidden;">
<table cellpadding="0" cellspacing="0" bgcolor="#edf2fc" width="100%" height="100%">
<tr>
<td>
<table cellspacing="0" cellpadding="0" width="100%" height="<?=$rs[po_height] - 20;?>">
<tr>
<td><div style="overflow:{overflow};"><?=$rs[po_content];?></div></td>
</tr>
</table>
<div style="background:#000000;color:#FFFFFF;text-align:left;padding-right:5px;;font-size:12px;">
<input type="checkbox" id="expirehours{id}" name="expirehours{id}" value="<?=$rs[po_expirehours];?>"><?=$rs[po_expirehours];?>시간 동안 이 창을 다시 열지 않음
<a href="javascript:layer_close(<?=$rs[po_id];?><?=($rs[po_actc])?",'{$rs[po_actc]}'":"";?>)"><img src="<?=$popup_skin_path;?>/img/close.jpg" width="11" height="11" border="0"></a>
</div>
</td>
</tr>
</table>
</div>
</div>
<script language='JavaScript'>
function ietruebody(){
return (document.compatMode && document.compatMode!="BackCompat" && !window.opera)? document.documentElement : document.body
}
<?if($rs[po_leftcenter]){?>
document.getElementById("pop{id}").style.left = (ietruebody().clientWidth / 2) + {po_left} + "px";
<?}else{?>
document.getElementById("pop{id}").style.left = {po_left} + "px";
<?}?>
<?if($rs[po_topcenter]){?>
document.getElementById("pop{id}").style.top = (ietruebody().clientHeight / 2) + {po_top} + "px";
<?}else{?>
document.getElementById("pop{id}").style.top = {po_top} + "px";
<?}?>
<?if(!$rs[po_act]){?>
document.getElementById("pop{id}").style.display = "";
<?}?>
selectbox_hidden("pop{id}");
<?if($rs[po_act] != "" && $rs[po_popstyle] == 1){?>
<?=$rs[po_act];?>(document.getElementById("pop{id}"),<?=$rs[po_delay];?>);
<?}?>
</script>
윈도우 팝업은 문제 없습니다.
그런데 레이어 팝업만 띄우고 '00동안 이 창을 보이지 않음'에 체크하고
닫기 버튼을 누르면 아무런 반응이 없습니다.
자바스크립트 오류가 생기는 것도 아니고...
일반 게시판에 팝업을 띄우면 제대로 동작하는데 그누보드 폴더 밖에 있는 index.php 파일에
팝업을 띄우니까 그러네요.
참고로 _common 파일도 넣었습니다.
layerview.php 파일입니다.
-----------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<style>
div{
scrollbar-face-color:#eeeeee;
scrollbar-highlight-color: #ffffff;
scrollbar-3dlight-color: #ffffff;
scrollbar-shadow-color: #cccccc;
scrollbar-darkshadow-color: #999999;
scrollbar-track-color: #eeeeee;
scrollbar-arrow-color: #999999
}
#pop{id}{
position:absolute;
z-index:{zindex};
width:{po_width}px;
height:{po_height}px;
filter:alpha(opacity=100);
overflow : hidden;
}
</style>
<div id="pop{id}" >
<div style="width:{po_width}px;overflow:hidden;">
<table cellpadding="0" cellspacing="0" bgcolor="#edf2fc" width="100%" height="100%">
<tr>
<td>
<table cellspacing="0" cellpadding="0" width="100%" height="<?=$rs[po_height] - 20;?>">
<tr>
<td><div style="overflow:{overflow};"><?=$rs[po_content];?></div></td>
</tr>
</table>
<div style="background:#000000;color:#FFFFFF;text-align:left;padding-right:5px;;font-size:12px;">
<input type="checkbox" id="expirehours{id}" name="expirehours{id}" value="<?=$rs[po_expirehours];?>"><?=$rs[po_expirehours];?>시간 동안 이 창을 다시 열지 않음
<a href="javascript:layer_close(<?=$rs[po_id];?><?=($rs[po_actc])?",'{$rs[po_actc]}'":"";?>)"><img src="<?=$popup_skin_path;?>/img/close.jpg" width="11" height="11" border="0"></a>
</div>
</td>
</tr>
</table>
</div>
</div>
<script language='JavaScript'>
function ietruebody(){
return (document.compatMode && document.compatMode!="BackCompat" && !window.opera)? document.documentElement : document.body
}
<?if($rs[po_leftcenter]){?>
document.getElementById("pop{id}").style.left = (ietruebody().clientWidth / 2) + {po_left} + "px";
<?}else{?>
document.getElementById("pop{id}").style.left = {po_left} + "px";
<?}?>
<?if($rs[po_topcenter]){?>
document.getElementById("pop{id}").style.top = (ietruebody().clientHeight / 2) + {po_top} + "px";
<?}else{?>
document.getElementById("pop{id}").style.top = {po_top} + "px";
<?}?>
<?if(!$rs[po_act]){?>
document.getElementById("pop{id}").style.display = "";
<?}?>
selectbox_hidden("pop{id}");
<?if($rs[po_act] != "" && $rs[po_popstyle] == 1){?>
<?=$rs[po_act];?>(document.getElementById("pop{id}"),<?=$rs[po_delay];?>);
<?}?>
</script>
댓글 전체