지에디터를 사용중인데 첨부파일이 아닌 이미지 추가시 리스트에 보이게 하고 싶습니다~ > 그누4 질문답변

그누4 질문답변

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

지에디터를 사용중인데 첨부파일이 아닌 이미지 추가시 리스트에 보이게 하고 싶습니다~ 정보

지에디터를 사용중인데 첨부파일이 아닌 이미지 추가시 리스트에 보이게 하고 싶습니다~

본문

제목 그대로 지에디터 사용중에 첨부파일로 추가한 이미지만 리스트페이지에 보이고

지에디터를 이용한 이미지 추가시에는 리스트에 no이미지가 표시됩니다.

아래 링크 보면서 따라 해봤으나 list.skin 소스가 전부 틀려서 어디를 손봐야할지를 모르겠습니다 ㅠㅠ



http://sir.co.kr/bbs/board.php?bo_table=g4_tiptech&wr_id=20040&sca=&sfl=wr_subject%7C%7Cwr_content&stx=%EC%97%90%EB%94%94%ED%84%B0+%EB%A6%AC%EC%8A%A4%ED%8A%B8


//////////////// 여기서부터 제가 사용중인 리스트 스킨입니다~

<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가

include_once("$board_skin_path/skin.lib.php");


$thumb_width = '150';  //썸네일 폭
$thumb_height = '150'; //썸네일 높이
$thumb_quality = '100'; //썸네일 퀄리티_100 이하
if (!function_exists("imagecopyresampled")) alert("GD 2.0.1 이상 버전이 설치되어 있어야 사용할 수 있는 갤러리 게시판 입니다.");

if (!$board[bo_1]) {
    $board[bo_1] = "230";
    $sql = " update $g4[board_table] set bo_1 = '$board[bo_1]', bo_1_subj = '목록 가로 픽셀' where bo_table = '$bo_table' ";
    sql_query($sql);
}

if (!$board[bo_2]) {
    $board[bo_2] = "1000";
    $sql = " update $g4[board_table] set bo_2 = '$board[bo_2]', bo_2_subj = '목록 세로 픽셀' where bo_table = '$bo_table' ";
    sql_query($sql);
}

$mod = $board[bo_gallery_cols];
$td_width = (int)(100 / $mod);

$data_path = $g4[path]."/data/file/$bo_table";
$thumb_path = $data_path.'/thumb';


@mkdir($thumb_path, 0707);
@chmod($thumb_path, 0707);




?>

<link rel="stylesheet" type="text/css" href="<?=$board_skin_path?>/css/skin.css" media="screen" />
<!-- Arquivos utilizados pelo jQuery lightBox plugin -->
<link rel="stylesheet" type="text/css" href="<?=$board_skin_path?>/css/jquery.lightbox-0.5.css" media="screen" />

<style>

#screenshot img{
width:150px;
height:150px;
}

#screenshot{
position:absolute;
border:1px solid #ccc;
background:#333;
padding:5px;
display:none;
color:#fff;
}

</style>

<script type="text/javascript" src="<?=$board_skin_path?>/js/jquery.lightbox-0.5.js"></script>
<script type="text/javascript">
$(function() {
$('#gallery .gall a').lightBox();
});
</script>


<div style="border-bottom:1px solid #cccccc; padding-bottom:10px; padding-top:10px; background-color:#f3f3f3;">
<? if ($is_category) { ?>

<form name='fcategory' method='get'>
<font color='#5a5a5a'>
  <? 
  $cnt_bo_1 = $bo_1[0] ? $bo_1[0] : 10; // 한줄당 분류 갯수(현재:10)
  $cnt = 1;
  $cnt0 = 0;
  $bb_s="";  $bb_e="";
  $arr = explode("|", $board[bo_category_list]); // 구분자가 , 로 되어 있음
$str = "";
$str .= "";
  $f_open="";
  $f_close="";
  for ($i=0; $i<count($arr); $i++)
  if (trim($arr[$i]))  {
$sql1 = " SELECT count(*) as cCount FROM $write_table where wr_is_comment = 0 and ca_name = '$arr[$i]' ";
  $row1 = sql_fetch($sql1);
if ($sca == $arr[$i]) { $cnt0++; $b_s="<b>";$cc=$f_open; $b_e="</b>"; } else {$b_s=""; $cc=$f_close; $b_e="";}
$str .= "<a href='./board.php?bo_table=$bo_table&sca=" . rawurlencode($arr[$i]) . "' style='color:black;'>$cc$b_s$arr[$i]$b_e</a> &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp; ";
if ($cnt == $cnt_bo_1) { $cnt = 0; $str .= "<br>"; }
$cnt++;
  }
  if ($cnt0 == 0 ) { $bb_s="<b>"; $bb_e="</b>"; }
  ?> 



&nbsp;&nbsp;&nbsp;&nbsp;
<? if(!$sca) { ?>
<a href="./board.php?bo_table=<?=$bo_table?>" style="color:black;"><b>전체 보기</b></a> &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;
<? } else { ?>
<a href="./board.php?bo_table=<?=$bo_table?>" style="color:black;">전체 보기</a> &nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;
<? } ?>
<?=$str?>

  </form>

<? } ?>




</div>
<!-- 게시판 목록 시작 -->
<table width="<?=$width?>" align="center" cellpadding="0" cellspacing="0"><tr><td>

<!--    <? if ($is_category) { ?><form name="fcategory" method="get"><div><select name=sca onchange="location='<?=$category_location?>'+this.value;"><option value=''>전체</option><?=$category_option?></select></div></form><? } ?>
 -->





<form name="fboardlist" method="post" style="margin:0px;">
<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="">

<div id="gallery">
<table border="0" cellpadding="0" cellspacing="0" width="100%">

<!-- tr>
  <td height=30 colspan='<?=$mod?>' align="right" style="border:1px solid #ddd; height:34px; background:url(<?=$board_skin_path?>/img/title_bg.gif) repeat-x;"><?=subject_sort_link('wr_datetime', $qstr2, 1)?>날짜순</a> | <?=subject_sort_link('wr_hit', $qstr2, 1)?>조회순</a> | <?=subject_sort_link('wr_good', $qstr2, 1)?>추천순</a></td>
</tr  -->

<tr>
 <?
    for ($i=0; $i<count($list); $i++) {
        if ($i && $i%$mod==0)
            echo "</tr><tr>";

        $style = "";
        $list[$i][subject] = str_replace(" ","&nbsp;",$list[$i][subject]);
$image = $list[$i][file][0][file];

        $comment_cnt = "";
        if ($list[$i][comment_cnt])
          $comment_cnt = " <a href=\"{$list[$i][comment_href]}\"><span class='commentFont'>{$list[$i][comment_cnt]}</span></a>";

        $list[$i][name] = preg_replace("/<img /", "<img style='display:none;' ", $list[$i][name]);
        $list[$i][name] = preg_replace("/> <span/", "><span", $list[$i][name]);
        $list[$i][name] = preg_replace("/class='member'/", "", $list[$i][name]);

        echo "<td width='{$td_width}%' valign=top style='word-break:break-all; padding:3px;'>";
        echo "<table align=center>";
        echo "<tr><td height=5></td></tr>";
        echo "<tr><td align=center><div style='float:left; border:1px solid #ccc; background:#fff; padding:3px; font-size:0; line-height:0;'><div ><a href='{$list[$i][href]}'  class='screenshot' rel1='{$list[$i][file][0][path]}/{$list[$i][file][0][file]}' rel2='{$list[$i][file][0][path]}/{$list[$i][file][1][file]}' rel3='{$list[$i][file][0][path]}/{$list[$i][file][2][file]}' ".">".makeThumbs($g4[path]."/data/file/$bo_table", $list[$i][file][0][file], $board[bo_1], $board[bo_2])."</a></div></div></td></tr>";
        //echo "<tr><td align=center style='font-size:11px; color:#888;'>Date.".$list[$i][datetime2]." / Hit.".$list[$i][wr_hit]."</td></tr>";
        echo "<tr><td align=center>";
        //if ($is_category) echo "<a href='{$list[$i][ca_name_href]}'>[{$list[$i][ca_name]}]</a> ";
        echo "<a href='{$list[$i][href]}'>{$list[$i][subject]}</a>";
        //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 "</td></tr>";
        if ($is_checkbox) echo "<tr><td align=center><input type=checkbox name=chk_wr_id[] value='{$list[$i][wr_id]}'></td></tr>";
        echo "</table></td>\n";


    }


    // 나머지 td
    $cnt = $i%$mod;
    if ($cnt)
        for ($i=$cnt; $i<$mod; $i++)
            echo "<td width='{$td_width}%'>&nbsp;</td>";
    ?>

댓글 전체

http://cherry.godohosting.com/bbs/board.php?bo_table=g4b2

이런식으로 섬네일 뽑는거 말씀하시는거죠..

저 스킨에서 코드 뜯어서 쓰세요..

http://sir.co.kr/bbs/board.php?bo_table=g4_builder&wr_id=10583
스킨은 여기 빌더에 포함되어 있습니다.
전체 66,558 |RSS
그누4 질문답변 내용 검색

회원로그인

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