조회수가 없는 게시판에 조회수를 넣으려면...(포인트1000) > 그누4 질문답변

그누4 질문답변

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기
기존 게시물은 열람만 가능합니다.

조회수가 없는 게시판에 조회수를 넣으려면...(포인트1000) 정보

조회수가 없는 게시판에 조회수를 넣으려면...(포인트1000)

본문

 
위의 웹진형 게시판을 설치했습니다..
조회수를 볼수가  없기에 조회수를 보이게 하려합니다..
선배님들의 조언을 바랍니다..
 
 
 
---------------------------------------------------------------
list.skin.php
 
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
// 게시판 설정
if (!$board[bo_10]) $board[bo_10]="100"; // 이미지박스크기
// 제목이 두줄로 표시되는 경우 이 코드를 사용해 보세요.
// <nobr style='display:block; overflow:hidden; width:000px;'>제목</nobr>
$max = $board[bo_10] - 5 ; // 이미지의 가로세로(긴쪽)의 최대치.
$noIMG = $board_skin_path."/img/noimage.gif"; // URL
$resol = 80 ; // 생성되는 썸네일의 JPG압축률.(퍼센트%)
function smaller( $W, $H ) {
 global $max, $thum_W, $thum_H ;
 if ( $W > $H ) { //가로형일 경우.
  $thum_W = $max ;
  $thum_H = ceil( $H * ( $max / $W ) );
 }
 if ( $W < $H ) { //세로형일 경우.
  $thum_H = $max ;
  $thum_W = ceil( $W * ( $max / $H ) );
 }
 if ( $W == $H ) { //정사각형일 경우.
  $thum_W = ceil( $max * 0.8 );
  $thum_H = ceil( $max * 0.8 );
 }
 return $thum_W ;
 return $thum_H ;
}

function maker( $thum_W, $thum_H ) {
 global $thum, $resol, $ori, $ori_info ;
 //$newImg = ImageCreate($thum_W,$thum_H); // GD라이브러리 2.0 (이하일 경우)
 $newImg = ImageCreateTrueColor($thum_W,$thum_H); // GD라이브러리 2.0 전용함수
  
 if($ori_info[2]=="2") $origImg=ImageCreateFromjpeg($ori);
 if($ori_info[2]=="3") $origImg=ImageCreateFrompng($ori);
  
 //ImageCopyResized($newImg,$origImg,0,0,0,0,$thum_W,$thum_H,ImageSX($origImg),ImageSY($origImg));
 imageCopyResampled($newImg,$origImg,0,0,0,0,$thum_W,$thum_H,ImageSX($origImg),ImageSY($origImg));
  
 Imagejpeg($newImg, $thum, $resol );
  
 @chmod($thum,0707);
 ImageDestroy($newImg);
 ImageDestroy($origImg);
 return $thum ;
}

##########################################
function showtextintags($text)   {
   $text = preg_replace("/(\<script)(.*?)(script>)/si", "dada", "$text");
   $text = strip_tags($text);
   $text = str_replace("<!--", "<!--", $text);
   $text = preg_replace("/(\<)(.*?)(--\>)/mi", "".nl2br("\\2")."", $text);
   return $text;
   }
##########################################
 
// 선택옵션으로 인해 셀합치기가 가변적으로 변함
$colspan = 10;
if ($is_category) $colspan++;
if ($is_checkbox) $colspan++;
if ($is_good) $colspan++;
if ($is_nogood) $colspan++;
// 제목이 두줄로 표시되는 경우 이 코드를 사용해 보세요.
// <nobr style='display:block; overflow:hidden; width:000px;'>제목</nobr>
?>
<style type="text/css">
<!--
.w_fixed { table-layout:fixed; }
.w_font  { font-family:돋움; font-size:9pt; color:#5E5E5E; }
.w_title { font-family:돋움; font-size:9pt; color:#5E5E5E; }
.w_num { font-family:돋움; font-size:9pt; color:#7BB2D6; }
.w_list { font-family:돋움; font-size:9pt; color:#6A6A6A; }
.w_notice { font-family:돋움; font-size:9pt; color:#2C88B9; }
.w_comment_cnt { font-family:돋움; font-size:8pt; color:#9A9A9A; }
.w_padding { PADDING-LEFT: 15px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px; }
.w_padding2 { PADDING-LEFT: 15px; PADDING-TOP: 5px; }
.w_text  { BORDER: #D3D3D3 1px solid; HEIGHT: 18px; BACKGROUND-COLOR: #ffffff; }
.w_textarea  { BORDER: #D3D3D3 1px solid; BACKGROUND-COLOR: #ffffff; WIDTH: 100%; WORD-BREAK: break-all; }
.w_message  { font-family:돋움; font-size:9pt; color:#4B4B4B; }
.w_norobot  { font-family:돋움; font-size:9pt; color:#BB4681; }
.title_han {color:FFFFFF;font-weight:bold;font-size:9pt}
.list_han {color:13485D;font-size:9pt;text-decoration:none;text-decoration:none}
.title_eng {font-family:tahoma;color:FFFFFF;font-weight:bold;font-size:8pt;text-decoration:none}
.list_eng {font-family:tahoma;color:13485D;font-size:8pt;text-decoration:none}
.head_01 {font-family:verdana;font-size:8pt;color:#555555}
.head_02 {font-family:verdana;font-size:8pt;color:#555555;font-weight:bold;text-decoration:underline}
-->
</style>
<!-- 상단 타이틀 라인 부분 -->
<table width="<?=$width?>" border="0" cellspacing="0" cellpadding="0" align=center>
<tr><td colspan=5 height="5" bgcolor='#<?=$board[bo_3]?>'></td></tr>
<tr>
<td width='15'></td>
<td width="3"><table width="1" height="35" cellpadding=0 cellspacing=0><tr><td bgcolor='#<?=$board[bo_3]?>' height="15"></td></tr><tr><td></td></tr></table></td>
<td width="100" align='center'><b>공지사항</b></td>
<td width="3"><table width="1" height="35" cellpadding=0 cellspacing=0><tr><td bgcolor='#<?=$board[bo_3]?>' height="15"></td></tr><tr><td></td></tr></table></td>
<td></td>
<tr><td colspan=5 height="1" bgcolor="#ECECEC"></td></tr>
<tr><td colspan=5 height="1" bgcolor="#FFFFFF"></td></tr>
<tr><td colspan=5 height="1" bgcolor="#C4C4C4"></td></tr>
</tr>
</table>

<table width="<?=$width?>" align="center" cellpadding="0" cellspcing="0"><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"><tr><td height="2"></td></tr></table>
<!-- 게시판 제목 시작 -->
<table width="100%" height=25 border=0 cellpadding=0 cellspacing=0 background="<?=$board_skin_path?>/img/board_t_bg.gif">
<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="">
<!-- 게시판 제목 끝 -->
<!-- 게시물 리스트 시작 -->

<? for ($i=0; $i<count($list); $i++) { ?>
<tr><td colspan="<?=$colspan?>" height="5" bgcolor=white></td></tr>
<tr height=28 class=list<?=($i%2)?> bgcolor='#FFFFFF'>
    <td width="40" align="center" valign="middle">
        <?
        //if ($list[$i][is_notice]) // 공지사항
            //echo "<img src=\"$board_skin_path/img/notice_icon.gif\" width=30 height=16>";
        //else if ($wr_id == $list[$i][wr_id]) // 현재위치
            //echo "<font class=list_eng><strong>{$list[$i][num]}</strong></font>";
        //else
            //echo "<font class=list_eng>{$list[$i][num]}</font>";
        ?></td>
    <? if ($is_checkbox) { ?><td width="40" align="center" valign="middle"><input type=checkbox name=chk_wr_id[] value="<?=$list[$i][wr_id]?>"></td> <? } ?>
<? // 이미지 처리부분
##################################################################################################
$thum = "";
$list_view = "";
$image = urlencode($list[$i][file][0][file]); // 첫번째 파일이 이미지라면
$images = "$g4[path]/data/file/$bo_table/$image";
if (preg_match("/\.(gif|jpg|png)$/i", $image) && file_exists("$g4[path]/data/file/$bo_table/$image")) {

 if (preg_match("/\.(gif|jpg|png)$/i", $image) && file_exists("$g4[path]/data/file/$bo_table/$image")) {
 $ori = "$g4[path]/data/file/$bo_table/$image"; //[필수](URL) "./img/Test.gif"
 }
 $ext = strtolower(substr(strrchr($ori,"."), 1)); //확장자
 if ( $ext=="gif"||$ext=="jpg"||$ext=="jpeg"||$ext=="png"||$ext=="bmp"||$ext=="tif"||$ext=="tiff")
  $ori_info=getimagesize($ori);
 else
  $ori_info="";
 //===== 원파일이 [ 2JPG, 2JPEG, 3PNG ] 경우
 if ( $ori_info[2]=="2" || $ori_info[2]=="3" ) {
  $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 );
  }
 }
 }
 //===== 원파일이 [ 1GIF,6BMP,7TIF ] 경우
 else if ( $ori_info[2]=="1" || $ori_info[2]=="6" || $ori_info[2]=="7" ) {
  if ( smaller( $ori_info[0], $ori_info[1] ) ) { $thum = $ori ; }
 }
 //===== 원파일이 [ 1,2,3,6,7 ] 아닐 경우
 else {
  $thum = $noIMG ;
  $noIMG_info = getimagesize ($noIMG);
  $thum_W = $noIMG_info[0] ;
  $thum_H = $noIMG_info[1] ;
 }
   $list_view = "<img src='$thum' width='$thum_W' height='$thum_H' border=0 align=absmiddle style='border-width:1; border-color:rgb(102,102,102); border-style:solid;'>";
} else if (preg_match("/\.($config[cf_flash_extension])$/i", $image)) {
 
   $list_view = "<embed src='$images' width='96' height='72' style='border-width:1; border-color:rgb(102,102,102); border-style:solid;'></embed>";
  
} else if (preg_match("/\.($config[cf_movie_extension])$/i", $image)) {  
 
   $list_view = "<embed src='$images' width='96' height='72' style='border-width:1; border-color:rgb(102,102,102); border-style:solid;'></embed>";
  
} else { $list_view = "<img src='$noIMG' alt='이미지 없음' width='96' height='72' style='border-width:1; border-color:rgb(102,102,102); border-style:solid;'>"; }
  
##################################################################################################
?>
<td width='110' align="left" valign="middle" style='word-break:break-all;'>
    <a href='<?=$list[$i][href]?>'><?=$list_view?></a>
  </td>
    <td width='' align="left" valign="middle" style='word-break:break-all;'>
        <?
        echo $nobr_begin;
        echo $list[$i][reply];
        echo $list[$i][icon_reply];
        echo "<a href='{$list[$i][href]}'>"; // 제목에 링크 시작
  if ($list[$i][is_notice])
            echo "<img src='{$board_skin_path}/img/icon.gif' border=0> <font class=head_02>{$list[$i][subject]}</font>";
        else
            echo "<img src='{$board_skin_path}/img/icon.gif' border=0> <font class=head_02>{$list[$i][subject]}</font>";
        echo "</a>"; // 제목에 링크 끝
  echo "{$list[$i][icon_new]}"; // 최신글 아이콘 출력
        if ($list[$i][comment_cnt])
            echo " <a href=\"{$list[$i][comment_href]}\"><span class=w_comment_cnt>{$list[$i][comment_cnt]}</a>";
    $wr_content=$list[$i][wr_content];   
    $wr_content =  showtextintags($wr_content);
    $wr_content=cut_str($wr_content,200, '...');
    //echo"$wr_content";
     
   // 내용 출력 길이 제한 부분
           //?><!-- <font color="#666666"><br><br><?//=cut_str($list[$i][wr_content],200,"...");?></font>--> <?//
           ?><font color="#666666"><br><br><?=$wr_content?></font> <?
        // if ($list[$i]['link']['count']) { echo "[{$list[$i]['link']['count']}]"; }
        // if ($list[$i]['file']['count']) { echo "<{$list[$i]['file']['count']}>"; }
        //echo " " . $list[$i][icon_new];
        //echo " " . $list[$i][icon_file];
        //echo " " . $list[$i][icon_link];
        //echo " " . $list[$i][icon_hot];
        //echo " " . $list[$i][icon_secret];
        echo $nobr_end;
        ?>
        <? if ($is_category) { ?><br><font class=w_font><strong>□ <a href="<?=$list[$i][ca_name_href]?>"><?=$list[$i][ca_name]?></a></strong></font><? } ?>
        </td>
    <? if ($is_good) { ?><td width="40" align="center" valign="middle"><font class=list_eng><?=$list[$i][wr_good]?></font></td><? } ?>
    <? if ($is_nogood) { ?><td width="40" align="center" valign="middle"><font class=list_eng><?=$list[$i][wr_nogood]?></font></td><? } ?>
</tr>
<!-- 여백 --><tr><td colspan="<?=$colspan?>" height="15" bgcolor=white></td></tr>
<!-- 구분선 처리 --><tr><td colspan="<?=$colspan?>" height="1" bgcolor=#efefef></td></tr>
<? } ?>
<? if (count($list) == 0) { echo "<tr><td height=100 align=center>게시물이 없습니다.</td></tr>"; } ?>
</form>
</table>
<!-- 게시물 리스트 끝 -->
<!-- 페이지 표시 시작 -->
<? if ($write_pages) { ?>
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
    <td height="37" align="center" valign="middle" background="<?=$board_skin_path?>/img/number_line.gif">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
            <td width="100%" align="center">
                <? if ($prev_part_href) { echo "<a href='$prev_part_href'><img src='$board_skin_path/img/btn_search_prev.gif' width=50 height=20 border=0 align=absmiddle title='이전검색'></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'><img src='$board_skin_path/img/btn_search_next.gif' width=50 height=20 border=0 align=absmiddle title='다음검색'></a>"; } ?>
            </td>
        </tr>
        </table></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/list.gif" border="0" align="absmiddle"></a><? } ?>
        <? if ($write_href) { ?><a href="<?=$write_href?>"><img src="<?=$board_skin_path?>/img/write.gif" border="0" align="absmiddle"></a><? } ?>
        <? if ($is_checkbox) { ?>
            <a href="javascript:select_delete();"><img src="<?=$board_skin_path?>/img/allchkdel.gif" border="0" align="absmiddle"></a>
            <a href="javascript:select_copy('copy');"><img src="<?=$board_skin_path?>/img/copy.gif" border="0" align="absmiddle"></a>
            <a href="javascript:select_copy('move');"><img src="<?=$board_skin_path?>/img/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="50" height="20" src="<?=$board_skin_path?>/img/search.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 ($is_checkbox) { ?>
<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;
    }
}
function check_confirm(str)
{
    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 (!chk_count) {
        alert(str + "할 게시물을 하나 이상 선택하세요.");
        return false;
    }
    return true;
}
// 선택한 게시물 삭제
function select_delete()
{
    var f = document.fboardlist;
    str = "삭제";
    if (!check_confirm(str))
        return;
    if (!confirm("선택한 게시물을 정말 "+str+" 하시겠습니까?\n\n한번 "+str+"한 자료는 복구할 수 없습니다"))
        return;
    f.action = "./delete_all.php";
    f.submit();
}
// 선택한 게시물 복사 및 이동
function select_copy(sw)
{
    var f = document.fboardlist;
    if (sw == "copy")
        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>
<? } ?>
 
---------------------------------------------------------------------
view.skin.php
 
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
?>
<style>
.mystyle { font-size:9pt; color:#5E5E5E}
.v_padding1 { PADDING-LEFT: 5px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px; }
.v_padding2 { PADDING-LEFT: 5px; PADDING-right: 0px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px; }
.v_padding3 { PADDING-LEFT: 0px; PADDING-right: 0px; PADDING-BOTTOM: 7px; PADDING-TOP: 10px; }
.v_padding4 { PADDING-LEFT: 5px; PADDING-right: 0px; PADDING-BOTTOM: 5px; PADDING-TOP: 5px; }
.v_padding5 { PADDING-LEFT: 10px; PADDING-right: 20px; PADDING-BOTTOM: 7px; PADDING-TOP: 10px; }
.v_padding6 { PADDING-LEFT: 20px; PADDING-right: 20px; PADDING-BOTTOM: 20px; PADDING-TOP: 20px; }
.v_text1 { BORDER-RIGHT: #D3D3D3 1px solid; BORDER-TOP: #D3D3D3 1px solid; BORDER-LEFT: #D3D3D3 1px solid; BORDER-BOTTOM: #D3D3D3 1px solid; HEIGHT: 18px; BACKGROUND-COLOR: #ffffff; }
.v_contents {font-size:9pt;color:#000000; COLOR:#454545; }
.v_content {font-family:돋움,tahoma;font-size:9pt;color:#555555; line-height:180%}
.head_01 {font-family:verdana;font-size:8pt;color:#000000}
.head_02 {font-family:verdana;font-size:8pt;color:#000000;font-weight:bold;text-decoration:none}
</style>
<!-- 상단 타이틀 라인 부분 -->
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td colspan=3 height="5" bgcolor='#<?=$board[bo_3]?>'></td></tr>
<tr>
<td width='12'></td>
<td height="35"><b>공지사항</b></td>
<td></td>
<tr><td colspan=3 height="1" bgcolor="#ECECEC"></td></tr>
<tr><td colspan=3 height="1" bgcolor="#FFFFFF"></td></tr>
<tr><td colspan=3 height="1" bgcolor="#C4C4C4"></td></tr>
</tr>
</table>
<!-- 제일 큰 테이블 시작 부분 -->
<table width="<?=$width?>" align="center" cellpadding="0" cellspcing="0" border=0><tr><td>
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
   <td>
        <table border=0 cellpadding=3 cellspacing=1 width=100%>
  <tr>
  <td width=60> <font class=head_02>작성일</font></td><td> <?=substr($view[wr_datetime],2,14)?>     </td>
  </tr>
        <tr>
   <td> <font class=head_02>작성자</font></td><td>  <font class="mystyle"><?=$view[name]?></font><? if ($is_ip_view) { echo " ($ip)"; } ?></td>
 </tr>
        <tr>
   <td> <font class=head_02>글제목</font></td><td>  <font color=#0066CC><b><? if ($is_category) { echo ($category_name ? "[$view[ca_name]] " : ""); } ?><?=$view[subject]?></b></font></td>
 </tr>  
        </table>
   </td>
</tr>  
</table>
<tr><td height=1 background="<?=$board_skin_path?>/img/board_line.gif"></td></tr>
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
<? if ($trackback_url) { ?>
<tr>
    <td colspan="3" align="right" class=v_padding3>
        트랙백 주소 : <a href="javascript:clipboard_trackback('<?=$trackback_url?>');" style="letter-spacing:0;" title='이 글을 소개할 때는 이 주소를 사용하세요'><?=$trackback_url?></a> 
        <script language="JavaScript">
            function clipboard_trackback(str) {
                if (g4_is_gecko)
                    prompt("이 글의 고유주소입니다. Ctrl+C를 눌러 복사하세요.", str);
                else if (g4_is_ie) {
                    window.clipboardData.setData("Text", str);
                    alert("트랙백 주소가 복사되었습니다.\n\n<?=$trackback_url?>");
                }
            }
        </script>
    </td>
</tr>
<tr>
    <td height="1" colspan="3" align="right" background="<?=$board_skin_path?>/img/dot_bg.gif"></td>
</tr>
<? } ?>
<?
// 가변 파일
$cnt = 0;
for ($i=0; $i<count($view[file]); $i++) {
    if ($view[file][$i][source] && !$view[file][$i][view]) {
        $cnt++;
        echo <<<HEREDOC
        <tr>
            <td width="20" class=v_padding3><img src="{$board_skin_path}/img/file_icon.gif" width="13" height="13"></td>
            <td width="20" class=v_padding3><font class="mystyle">#{$cnt}</font></td>
            <td class=v_padding5><a href='{$view[file][$i][href]}' title='{$view[file][$i][content]}'><font class="mystyle">{$view[file][$i][source]} ({$view[file][$i][size]}), Down:{$view[file][$i][download]}, {$view[file][$i][datetime]}</FONT></a></td>
        </tr>
        <tr>
            <td height="1" colspan="3" align="right" background="{$board_skin_path}/img/dot_bg.gif"></td>
        </tr>
HEREDOC;
    }
}
// 링크
$cnt = 0;
for ($i=1; $i<=$g4[link_count]; $i++) {
    if ($view[link][$i]) {
        $cnt++;
        $link = cut_str($view[link][$i], 70);
        echo <<<HEREDOC
        <tr>
            <td width="20" class=v_padding3><img src="{$board_skin_path}/img/link_icon.gif" width="13" height="13"></td>
            <td width="20" class=v_padding3><font class="mystyle">#{$cnt}</font></td>
            <td class=v_padding5><a href="{$view[link_href][$i]}" target="_blank"><font class="mystyle">{$link} ({$view[link_hit][$i]})</FONT></a></td>
        </tr>
        <tr>
            <td height="1" colspan="3" align="right" background="{$board_skin_path}/img/dot_bg.gif"></td>
        </tr>
HEREDOC;
    }
}
?>
<tr>
    <td height="200" colspan="3" valign="top" class=v_padding6 style='word-break:break-all;'>
        <? 
        // 파일 출력
        for ($i=0; $i<=count($view[file]); $i++) {
            if ($view[file][$i][view])
                echo  $view[file][$i][view] . "<p>";
        }
         ?>
        <span class="v_content"><?=$view[content];?></span>
        <?//echo $view[rich_content]; // {img:0} 과 같은 코드를 사용할 경우?>
        <!-- 테러 태그 방지용 --></xml></xmp><a href=""></a><a href=''></a></td>
</tr>
<? if ($is_signature) { echo "<tr><td align=right>$signature<br><br></td></tr>"; } // 서명 출력 ?>
</table>
<?
//include_once("./view_comment.php"); // 코멘트 출력 안하기
?>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td colspan=3 height="1" bgcolor="#ECECEC"></td></tr>
<tr><td colspan=3 height="1" bgcolor="#FFFFFF"></td></tr>
<tr><td colspan=3 height="1" bgcolor="#C4C4C4"></td></tr>
</tr>
</table>

<!-- 이전글/다음글 제목 보여주기 -->
<? /* ------------------------------------------------------------------------------------------   ?>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td height=10></td></tr>
<? if ($prev_href || $next_href) { ?>
<tr><td height=1 bgcolor="#B5B5B5"></td></tr>
<tr>
 <td height=25 class=bbs_pl>
  <img src='<?=$board_skin_path?>/img/list_prev.gif' border=0 width=10 height=11 align=absmiddle>  이전글 : <a href="<?=$prev_href?>" title="이전글"><?=$prev_wr_subject?></a>
  <? if (!$prev_href) { echo "등록된 글이 없습니다.";} ?>
 </td>
</tr>
<tr><td height=1 bgcolor="#E3E3E3"></td></tr>
<tr>
 <td height=25 class=bbs_pl>
  <img src='<?=$board_skin_path?>/img/list_next.gif' border=0 width=10 height=11 align=absmiddle>  다음글 : <a href="<?=$next_href?>" title="다음글"><?=$next_wr_subject?></a>
  <? if (!$next_href) { echo "등록된 글이 없습니다.";} ?>
 </td>
</tr>
<tr><td height=1 bgcolor="#B5B5B5"></td></tr>
</table>
<? } ?>
<?  ------------------------------------------------------------------------------------------ */ ?>
<!-- 링크 버튼 -->
<?
ob_start();
?>
<table width='100%' cellpadding=0 cellspacing=0 align="center" border=0>
<tr>
    <td width=80% height=35>
        <? if ($search_href) { echo "<a href=\"$search_href\"><img src='$board_skin_path/img/btn_search_list.gif' border='0' align='absmiddle'></a> "; } ?>
        <? echo "<a href=\"$list_href\"><img src='$board_skin_path/img/list.gif' border='0' align='absmiddle'></a> "; ?>
        <? if ($write_href) { echo "<a href=\"$write_href\"><img src='$board_skin_path/img/write.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($reply_href) { echo "<a href=\"$reply_href\"><img src='$board_skin_path/img/reply.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($update_href) { echo "<a href=\"$update_href\"><img src='$board_skin_path/img/edit.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($delete_href) { echo "<a href=\"$delete_href\"><img src='$board_skin_path/img/delete.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($good_href) { echo "<a href=\"$good_href\" target='hiddenframe'><img src='$board_skin_path/img/recomm.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($nogood_href) { echo "<a href=\"$nogood_href\" target='hiddenframe'><img src='$board_skin_path/img/norecom.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($copy_href) { echo "<a href=\"$copy_href\"><img src='$board_skin_path/img/copy.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($move_href) { echo "<a href=\"$move_href\"><img src='$board_skin_path/img/move.gif' border='0' align='absmiddle'></a> "; } ?>
       
        <? if ($scrap_href) { echo "<a href=\"javascript:;\" onclick=\"win_scrap('./scrap_popin.php?bo_table=$bo_table&wr_id=$wr_id');\"><img src='$board_skin_path/img/btn_scrap.gif' border='0' align='absmiddle'></a> "; } ?>
    </td>
    <td width=20% align=right>
        <? if ($prev_href) { echo "<a href=\"$prev_href\" title=\"$prev_wr_subject\"><img src='$board_skin_path/img/btn_prev.gif' border='0' align='absmiddle'></a> "; } ?>
        <? if ($next_href) { echo "<a href=\"$next_href\" title=\"$next_wr_subject\"><img src='$board_skin_path/img/btn_next.gif' border='0' align='absmiddle'></a> "; } ?>
    </td>
</tr>
</table>
<?
$link_buttons = ob_get_contents();
ob_end_flush();
?>
<!--</td></tr></table> -->
<script language="JavaScript">
// HTML 로 넘어온 <img ... > 태그의 폭이 테이블폭보다 크다면 테이블폭을 적용한다.
function resize_image()
{
    var target = document.getElementsByName('target_resize_image[]');
    var image_width = parseInt('<?=$board[bo_image_width]?>');
    var image_height = 0;
    for(i=0; i<target.length; i++) {
        // 원래 사이즈를 저장해 놓는다
        target[i].tmp_width  = target[i].width;
        target[i].tmp_height = target[i].height;
        // 이미지 폭이 테이블 폭보다 크다면 테이블폭에 맞춘다
        if(target[i].width > image_width) {
            image_height = parseFloat(target[i].width / target[i].height)
            target[i].width = image_width;
            target[i].height = parseInt(image_width / image_height);
        }
    }
}
window.onload = resize_image;
</script>

댓글 전체

전체 66,554 |RSS
그누4 질문답변 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1402호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT