이것 목록에서 바로 팝업창으로 정보
이것 목록에서 바로 팝업창으로본문
아래것은 겔러리 스킨 list_skin.php 인데요
목록에서 썸네일 클릭하면 그림만 팝업창 띄우려면 어떻하나요...?
<?
include_once $board_skin_path."/_include.php";
?>
include_once $board_skin_path."/_include.php";
?>
<?
//$image_width = 100; // 이미지 폭
//$image_height = 100; // 이미지 높이
?>
//$image_width = 100; // 이미지 폭
//$image_height = 100; // 이미지 높이
?>
<!-- 분류 셀렉트 박스, 게시물 몇건, 관리자화면 링크 시작 -->
<table width='<?=$width?>' align=center><tr><td>
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<? if ($is_category) { ?><form name="fcategory" method="get">
<td width="50%"><select name=sca onchange="location='<?=$category_location?>'+this.value;"><option value=''>전체</option><?=$category_option?></select></td>
</form><? } ?>
<td height=25 align="right"><font class=w_font>게시물 <?=number_format($total_count)?>건</font><? if ($admin_href) { ?><a href="<?=$admin_href?>"><img src="<?=$board_skin_path?>/img/admin_button.gif" title="관리자" width="63" height="22" border="0" align="absmiddle"></a><? } ?></td>
</tr>
</table>
<!-- 분류 셀렉트 박스, 게시물 몇건, 관리자화면 링크 끝 -->
<table width='<?=$width?>' align=center><tr><td>
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<? if ($is_category) { ?><form name="fcategory" method="get">
<td width="50%"><select name=sca onchange="location='<?=$category_location?>'+this.value;"><option value=''>전체</option><?=$category_option?></select></td>
</form><? } ?>
<td height=25 align="right"><font class=w_font>게시물 <?=number_format($total_count)?>건</font><? if ($admin_href) { ?><a href="<?=$admin_href?>"><img src="<?=$board_skin_path?>/img/admin_button.gif" title="관리자" width="63" height="22" border="0" align="absmiddle"></a><? } ?></td>
</tr>
</table>
<!-- 분류 셀렉트 박스, 게시물 몇건, 관리자화면 링크 끝 -->
<!-- 게시판 제목 시작 -->
<table width="100%" cellspacing="0" cellpadding="0">
<form name="fboardlist" method="post">
<input type="hidden" name="bo_table" value="<?=$bo_table?>">
<input type="hidden" name="sfl" value="<?=$sfl?>">
<input type="hidden" name="stx" value="<?=$stx?>">
<input type="hidden" name="spt" value="<?=$spt?>">
<input type="hidden" name="page" value="<?=$page?>">
<input type="hidden" name="sw" value="">
<tr><td height="2" bgcolor="#86CAD7"></td></tr>
</table>
<!-- 여백 -->
<table width="100%" cellspacing="0" cellpadding="0"><tr><td height="10"></td></tr></table>
<?
// 번호에 이미지를 사용할 경우는 아래의 주석을 제거하고 $list[$i][num]의 내용을 수정후 사용하세요.
// if (!is_int($list[$i][num])) { $list[$i][num] = "<img src='$board_skin/img/arrow.gif'>"; }
?>
<table width="100%" cellspacing="0" cellpadding="0">
<form name="fboardlist" method="post">
<input type="hidden" name="bo_table" value="<?=$bo_table?>">
<input type="hidden" name="sfl" value="<?=$sfl?>">
<input type="hidden" name="stx" value="<?=$stx?>">
<input type="hidden" name="spt" value="<?=$spt?>">
<input type="hidden" name="page" value="<?=$page?>">
<input type="hidden" name="sw" value="">
<tr><td height="2" bgcolor="#86CAD7"></td></tr>
</table>
<!-- 여백 -->
<table width="100%" cellspacing="0" cellpadding="0"><tr><td height="10"></td></tr></table>
<?
// 번호에 이미지를 사용할 경우는 아래의 주석을 제거하고 $list[$i][num]의 내용을 수정후 사용하세요.
// if (!is_int($list[$i][num])) { $list[$i][num] = "<img src='$board_skin/img/arrow.gif'>"; }
?>
<!-- 여기부터 반복 부분 =================================================================================================================== -->
<table width=99% align=center cellpadding=3 border=0 >
<tr>
<?
for ($i=0; $i<count($list); $i++) {
<tr>
<?
for ($i=0; $i<count($list); $i++) {
$tr = "";
if ($i && $i%$board[bo_gallery_cols]==0) {
$tr = "</tr><tr>";
}
echo "$tr";
if ($i && $i%$board[bo_gallery_cols]==0) {
$tr = "</tr><tr>";
}
echo "$tr";
//if (!file_exists($list[$i][file_image1])) { $list[$i][file_image1] = "$board_skin/noimage.gif"; }
####################################################################################################################################################
//$ori = $list[$i][file_image1]; //[필수](URL) "./img/Test.gif"
$image = urlencode($list[$i][file][0][file]);
$ori="$g4[path]/data/file/$bo_table/" . $image;
$ext = strtolower(substr(strrchr($ori,"."), 1)); //확장자
$image = urlencode($list[$i][file][0][file]);
$ori="$g4[path]/data/file/$bo_table/" . $image;
$ext = strtolower(substr(strrchr($ori,"."), 1)); //확장자
//if ( file_exists($ori) ) $ori_info=getimagesize($ori); else $ori_info=""; //파일이 있을 경우, 확장자 지정.
if ( $ext=="gif"||$ext=="jpg"||$ext=="jpeg"||$ext=="png"||$ext=="bmp"||$ext=="tif"||$ext=="tiff") $ori_info=getimagesize($ori); else $ori_info="";
if ( $ext=="gif"||$ext=="jpg"||$ext=="jpeg"||$ext=="png"||$ext=="bmp"||$ext=="tif"||$ext=="tiff") $ori_info=getimagesize($ori); else $ori_info="";
if ( $ori_info[2]=="2" || $ori_info[2]=="3" ) { //============================================================ 원파일이 [ 2JPG, 2JPEG, 3PNG ] 경우.
$thum = $ori.".Thum" ;
if ( file_exists($thum) ) { // Thumbnail [O] 경우
$thum_info = getimagesize ($thum);
$thum_W = $thum_info[0] ;
$thum_H = $thum_info[1] ;
} else { // Thumbnail [X] 경우
if ( smaller( $ori_info[0], $ori_info[1] ) ) {
maker( $thum_W, $thum_H );
}
}
}
}
} else if ( $ori_info[2]=="1" || $ori_info[2]=="6" || $ori_info[2]=="7" ) { //=================== 원파일이 [ 1GIF,6BMP,7TIF ] 경우.
if ( smaller( $ori_info[0], $ori_info[1] ) ) {
$thum = $ori ;
}
}
} else { //========================================================================================= 원파일이 [ 1,2,3,6,7 ] 아닐 경우.
$thum = $noIMG ;
$noIMG_info = getimagesize ($noIMG);
$thum_W = $noIMG_info[0] ;
$thum_H = $noIMG_info[1] ;
}
####################################################################################################################################################
$noIMG_info = getimagesize ($noIMG);
$thum_W = $noIMG_info[0] ;
$thum_H = $noIMG_info[1] ;
}
####################################################################################################################################################
?>
<td width='<?=$td_width?>%' valign=top align=center>
<table cellpadding=10 cellspacing=10 width="" align=center height=80 style="border-top-width:1; border-right-width:1; border-bottom-width:1; border-left-width:1;d5d5d5rder-color:#6ABCD7; border-top-style:solid; border-left-style:solid; border-bottom-style:solid; border-right-style:solid;">
<tr>
<td !align=center !valign=middle !bgcolor=#cccccc style='padding:5;'>
<a href='<?=$list[$i][href]?>' onfocus=blur()><img src='<?=$thum?>' width='<?=$thum_W?>' height='<?=$thum_H?>' alt='<?=$list[$i][wr_subject]?>' border=0></a></td>
</tr>
</table>
<tr>
<td !align=center !valign=middle !bgcolor=#cccccc style='padding:5;'>
<a href='<?=$list[$i][href]?>' onfocus=blur()><img src='<?=$thum?>' width='<?=$thum_W?>' height='<?=$thum_H?>' alt='<?=$list[$i][wr_subject]?>' border=0></a></td>
</tr>
</table>
<table height=5 cellspacing=0 ><tr><td></td></tr></table>
<? if ($is_checkbox) { ?><input type=checkbox name=chk_wr_id[] value="<?=$list[$i][wr_id]?>"><? } ?> <a href='<?=$list[$i][href]?>'><? if ($list[$i][is_notice]) echo "<b>"; ?><?=cut_str($list[$i][subject],$str,"…");?></a> <? if ($list[$i][is_notice]) echo "</b>"; ?>
<? if ($list[$i][comment_cnt])
echo " <a href=\"{$list[$i][comment_href]}\"><span class=w_comment_cnt>{$list[$i][comment_cnt]}</a>";?>
<?=$list[$i][icon_new]?><?=$list[$i][icon_hot]?><?=$list[$i][icon_secret]?>
</td>
<? if ($list[$i][comment_cnt])
echo " <a href=\"{$list[$i][comment_href]}\"><span class=w_comment_cnt>{$list[$i][comment_cnt]}</a>";?>
<?=$list[$i][icon_new]?><?=$list[$i][icon_hot]?><?=$list[$i][icon_secret]?>
</td>
<? }
if (count($list) == 0) { echo "<tr><td colspan=8 align=center height=100 class='content'>자료가 없습니다.</td></tr>"; }
if (count($list) == 0) { echo "<tr><td colspan=8 align=center height=100 class='content'>자료가 없습니다.</td></tr>"; }
?>
</form>
</table>
</table>
<!-- 여기까지 반복 부분 =================================================================================================================== -->
<!-- 페이지 표시 시작 -->
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td height="35" align="center" valign="middle" background="<?=$board_skin_path?>/img/number_line.gif">
<table width="500" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100%" align="center">
<? if ($prev_part_href) { echo "<a href='$prev_part_href'>이전검색</a>"; } ?>
<?
// 기본으로 넘어오는 페이지를 아래와 같이 변환하여 이미지로도 출력할 수 있습니다.
//echo $write_pages;
$write_pages = str_replace("처음", "<img src='$board_skin_path/img/begin.gif' border='0' align='absmiddle' title='처음'>", $write_pages);
$write_pages = str_replace("이전", "<img src='$board_skin_path/img/prev.gif' border='0' align='absmiddle' title='이전'>", $write_pages);
$write_pages = str_replace("다음", "<img src='$board_skin_path/img/next.gif' border='0' align='absmiddle' title='다음'>", $write_pages);
$write_pages = str_replace("맨끝", "<img src='$board_skin_path/img/end.gif' border='0' align='absmiddle' title='맨끝'>", $write_pages);
$write_pages = preg_replace("/<span>([0-9]*)<\/span>/", "<font style=\"font-family:돋움; font-size:9pt; color:#797979\">$1</font>", $write_pages);
$write_pages = preg_replace("/<b>([0-9]*)<\/b>/", "<font style=\"font-family:돋움; font-size:9pt; color:orange;\">$1</font>", $write_pages);
?>
<strong><?=$write_pages?></strong>
<? if ($next_part_href) { echo "<a href='$next_part_href'>다음검색</a>"; } ?>
</td>
</tr>
</table></td>
</tr><tr><td height=1 bgcolor=#f4f4f4></td></tr>
</table>
<table width="100%" cellspacing="0" cellpadding="0">
<tr align="left" valign="middle">
<td width="50%" height="40">
<? if ($list_href) { ?><a href="<?=$list_href?>"><img src="<?=$board_skin_path?>/img/btn_list.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($write_href) { ?><a href="<?=$write_href?>"><img src="<?=$board_skin_path?>/img/btn_write.gif" border="0" align="absmiddle"></a><? } ?>
<? if ($is_checkbox) { ?>
<a href="javascript:select_delete();"><img src="<?=$board_skin_path?>/img/btn_select_delete.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('copy');"><img src="<?=$board_skin_path?>/img/btn_select_copy.gif" border="0" align="absmiddle"></a>
<a href="javascript:select_copy('move');"><img src="<?=$board_skin_path?>/img/btn_select_move.gif" border="0" align="absmiddle"></a>
<? } ?>
</td>
<form name=fsearch method=get>
<input type=hidden name=bo_table value="<?=$bo_table?>">
<input type=hidden name=sca value="<?=$sca?>">
<td width="50%" align="right">
<select name=sfl>
<option value='wr_subject'>제목</option>
<option value='wr_content'>내용</option>
<option value='mb_id'>회원아이디</option>
<option value='wr_name'>이름</option>
</select>
<INPUT maxLength=15 size=10 name=stx itemname="검색어" required value="<?=$stx?>">
<SELECT name=sop>
<OPTION value=and>And</OPTION>
<OPTION value=or>Or</OPTION>
</SELECT>
</td>
<td width="10%" align="center"><INPUT type=image width="53" height="18" src="<?=$board_skin_path?>/img/search_btn.gif" border=0></td>
</form>
</tr>
</table>
</td></tr></table>
<script language="JavaScript">
if ("<?=$sca?>") document.fcategory.sca.value = "<?=$sca?>";
if ("<?=$stx?>") {
document.fsearch.sfl.value = "<?=$sfl?>";
document.fsearch.sop.value = "<?=$sop?>";
}
</script>
if ("<?=$sca?>") document.fcategory.sca.value = "<?=$sca?>";
if ("<?=$stx?>") {
document.fsearch.sfl.value = "<?=$sfl?>";
document.fsearch.sop.value = "<?=$sop?>";
}
</script>
<? if ($is_checkbox) { ?>
<script language="JavaScript">
function all_checked(sw)
{
var f = document.fboardlist;
<script language="JavaScript">
function all_checked(sw)
{
var f = document.fboardlist;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]")
f.elements[i].checked = sw;
}
}
if (f.elements[i].name == "chk_wr_id[]")
f.elements[i].checked = sw;
}
}
function check_confirm(str)
{
var f = document.fboardlist;
var chk_count = 0;
{
var f = document.fboardlist;
var chk_count = 0;
for (var i=0; i<f.length; i++) {
if (f.elements[i].name == "chk_wr_id[]" && f.elements[i].checked)
chk_count++;
}
if (f.elements[i].name == "chk_wr_id[]" && f.elements[i].checked)
chk_count++;
}
if (!chk_count) {
alert(str + "할 게시물을 하나 이상 선택하세요.");
return false;
}
return true;
}
alert(str + "할 게시물을 하나 이상 선택하세요.");
return false;
}
return true;
}
// 선택한 게시물 삭제
function select_delete()
{
var f = document.fboardlist;
function select_delete()
{
var f = document.fboardlist;
str = "삭제";
if (!check_confirm(str))
return;
if (!check_confirm(str))
return;
if (!confirm("선택한 게시물을 정말 "+str+" 하시겠습니까?\n\n한번 "+str+"한 자료는 복구할 수 없습니다"))
return;
return;
f.action = "./delete_all.php";
f.submit();
}
f.submit();
}
// 선택한 게시물 복사 및 이동
function select_copy(sw)
{
var f = document.fboardlist;
function select_copy(sw)
{
var f = document.fboardlist;
if (sw == "copy")
str = "복사";
else
str = "이동";
if (!check_confirm(str))
return;
str = "복사";
else
str = "이동";
if (!check_confirm(str))
return;
var sub_win = window.open("", "move", "left=50, top=50, width=396, height=550, scrollbars=1");
f.sw.value = sw;
f.target = "move";
f.action = "./move.php";
f.submit();
}
</script>
<? } ?>
f.target = "move";
f.action = "./move.php";
f.submit();
}
</script>
<? } ?>
댓글 전체
<td !align=center !valign=middle !bgcolor=#cccccc style='padding:5;'>
<a href='<?=$ori?>' onfocus=blur()><img src='<?=$thum?>' width='<?=$thum_W?>' height='<?=$thum_H?>' alt='<?=$list[$i][wr_subject]?>' border=0></a></td>
자바스크립 새창띄우기 적용하면 되겠네요.
<a href='<?=$ori?>' onfocus=blur()><img src='<?=$thum?>' width='<?=$thum_W?>' height='<?=$thum_H?>' alt='<?=$list[$i][wr_subject]?>' border=0></a></td>
자바스크립 새창띄우기 적용하면 되겠네요.
답변 감사합니다.
근데 팝업으로 뜨게하려면...?
제가 완전 초짜에요....
그림만은 뜨는데 팝업으로 안되네요...
근데 팝업으로 뜨게하려면...?
제가 완전 초짜에요....
그림만은 뜨는데 팝업으로 안되네요...