게시판 스킨 목록에서 이름, 조회수 안 나오게 하는 방법 좀 알려주세요 > 그누4 질문답변

그누4 질문답변

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

게시판 스킨 목록에서 이름, 조회수 안 나오게 하는 방법 좀 알려주세요 정보

게시판 스킨 목록에서 이름, 조회수 안 나오게 하는 방법 좀 알려주세요

본문

오류가 나는곳의 주소를 알려주시면 더 빠르고 정확하게 답변 받을 수 있습니다.

오류 주소 :

view.skin.php 에서 출력되는 이름은 지웠는데,
list.skin.php에서는 이름과 조회수를 지우면 아예 그 스킨 가로 사이즈가 줄더라구요.
어떻게 수정해야 하나요?

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

/*
* basic skin
*/

// 선택옵션으로 인해 셀합치기가 가변적으로 변함
$colspan = 5;

//if ($is_category) $colspan++;
if ($is_checkbox) $colspan++;
if ($is_good) $colspan++;
if ($is_nogood) $colspan++;
?>
<link rel="stylesheet" href="<?=$board_skin_path?>/theme.css" type="text/css">
<!-- .board_list start -->
<div class="board board_list">
<div class="list_header_aside">
<? if ($is_category) { ?>
<form id="category_selector">
<select name="sca" id="search_category">
<option value="">전체</option>
<?=$category_option?>
</select>
<input type="submit" value="이동" />
</form>

<script type="text/javascript">
$("#category_selector").find("select").bind("change",function(){
location.href = '<?=$category_location?>'+<?=strtolower($g4[charset])=='utf-8' ? "encodeURIComponent($(this).val())" : "$(this).val()"?>;
});
</script>
<? } ?>

<div id="list_aside">
총 게시글 수 <?=number_format($total_count)?>
<?/* if ($admin_href) { ?><a href="<?=$admin_href?>"><img src="<?=$board_skin_path?>/img/btn_admin.gif" alt="관리자 페이지" /></a><?}*/?>
</div>
</div>

<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="" />

    <table cellspacing="0">
<colgroup>
<col width="50" />
<? if ($is_checkbox) { ?><col width="40" /><? } ?>
<col class="m_view" />
<col class="m_view" width="110" />
<col width="40" />
<col width="50" />
<? if ($is_good) { ?><col width="40" /><? } ?>
<? if ($is_nogood) { ?><col width="40" /><? } ?>
</colgroup>
<thead>
<tr>
<th><span class="num">번호</span></th>
<? if ($is_checkbox) { ?><th><input onclick="if (this.checked) all_checked(true); else all_checked(false);" type="checkbox"></th><?}?>
<th class="m_view">제목</th>
<th class="m_view">글쓴이</th>
<th><?=subject_sort_link('wr_datetime', $qstr2, 1)?>작성일</a></th>
<th><?=subject_sort_link('wr_hit', $qstr2, 1)?>조회수</a></th>
<? if ($is_good) { ?><th><?=subject_sort_link('wr_good', $qstr2, 1)?>추천</a></th><?}?>
<? if ($is_nogood) { ?><th><?=subject_sort_link('wr_nogood', $qstr2, 1)?>비추천</a></th><?}?>
</tr>
</thead>
<tbody>
<?
for ($i=0; $i<count($list); $i++) {
$bg = $i%2 ? 0 : 1;
?>

<tr>
<td class="num">
<?
if ($list[$i][is_notice]) // 공지사항
echo "<strong>공지</strong>";
else if ($wr_id == $list[$i][wr_id]) // 현재위치
echo "<span class=\"current\">{$list[$i][num]}</span>";
else
echo $list[$i][num];
?>
</td>
<? if ($is_checkbox) { ?><td class="checkbox"><input type="checkbox" name="chk_wr_id[]" value="<?=$list[$i][wr_id]?>" /></td><? } ?>
<td class="subject m_view">
<?
echo $nobr_begin;
echo $list[$i][reply];
echo $list[$i][icon_reply];
if ($is_category && $list[$i][ca_name]) {
echo "<span class=\"category_name\">[<a href='{$list[$i][ca_name_href]}'>{$list[$i][ca_name]}</a>]</span> ";
}

if ($list[$i][is_notice])
echo "<a href=\"{$list[$i][href]}\"><span class=\"notice\">{$list[$i][subject]}</span></a>";
else
echo "<a href=\"{$list[$i][href]}\">{$list[$i][subject]}</a>";

$list[$i][comment_cnt] = str_replace("(","[",str_replace(")","]",$list[$i][comment_cnt]));

if ($list[$i][comment_cnt])
echo " <a href=\"{$list[$i][comment_href]}\"><span class=\"comment\">{$list[$i][comment_cnt]}</span></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 $nobr_end;
?>
</td>
<td class="name m_view"><?=$list[$i][name]?></td>
<td class="datetime"><?=$list[$i][datetime2]?></td>
<td class="hit"><?=$list[$i][wr_hit]?></td>
<? if ($is_good) { ?><td class="good"><?=$list[$i][wr_good]?></td><? } ?>
<? if ($is_nogood) { ?><td class="nogood"><?=$list[$i][wr_nogood]?></td><? } ?>
</tr>
<? } // end for ?>

<? if (count($list) == 0) { echo "<tr><td colspan='$colspan' class=\"m_view\"height=100 align=center>게시물이 없습니다.</td></tr>"; } ?>
</tbody>
</table>
</form>

<div class="board_button board_button_small">
<div style="float:left;">
<? if ($list_href) { ?>
<a href="<?=$list_href?>"><img src="<?=$board_skin_path?>/img/btn_list.gif" align="absmiddle" border='0'></a>
<? } ?>
<? if ($is_checkbox) { ?>
<button type="button" onclick="select_delete()">선택 삭제</button>
<button type="button" onclick="select_copy('copy')">선택 복사</button>
<button type="button" onclick="select_copy('move')">선택 이동</button>
<? } ?>
</div>

<div style="float:right;">
<? if ($write_href) { ?><a href="<?=$write_href?>"><span>글쓰기</span></a><? } ?>
</div>
</div>

<!-- 페이지 -->
<div class="board_page">
<? if ($prev_part_href) { echo "<a href='$prev_part_href'><img src='$board_skin_path/img/page_search_prev.gif' border='0' align=absmiddle title='이전검색'></a>"; } ?>
<?
// 기본으로 넘어오는 페이지를 아래와 같이 변환하여 이미지로도 출력할 수 있습니다.
//echo $write_pages;
$write_pages = str_replace("b>", "strong>", $write_pages);

$write_pages = str_replace(">처음", "class=\"nav\">처음", $write_pages);
$write_pages = str_replace(">이전", "class=\"nav\">이전", $write_pages);
$write_pages = str_replace(">다음", "class=\"nav\">다음", $write_pages);
$write_pages = str_replace(">맨끝", "class=\"nav\">맨끝", $write_pages);
/*
$write_pages = str_replace("처음", "<img src='$board_skin_path/img/page_begin.gif' border='0' align='absmiddle' title='처음'>", $write_pages);
$write_pages = str_replace("이전", "<img src='$board_skin_path/img/page_prev.gif' border='0' align='absmiddle' title='이전'>", $write_pages);
$write_pages = str_replace("다음", "<img src='$board_skin_path/img/page_next.gif' border='0' align='absmiddle' title='다음'>", $write_pages);
$write_pages = str_replace("맨끝", "<img src='$board_skin_path/img/page_end.gif' border='0' align='absmiddle' title='맨끝'>", $write_pages);
*/
?>
<?=$write_pages?>
<? if ($next_part_href) { echo "<a href='$next_part_href'><img src='$board_skin_path/img/page_search_next.gif' border='0' align=absmiddle title='다음검색'></a>"; } ?>
</div>
<?/* 기존 검색 사용하고 싶을 때..?>
<div class="board_search">
<form name="fsearch" method="get">
<input type="hidden" name="bo_table" value="<?=$bo_table?>" />
<input type="hidden" name="sop" value="and" />
<input type="hidden" name="sca"      value="<?=$sca?>" />
<select name="sfl">
<option value="wr_subject">제목</option>
<option value="wr_content">내용</option>
<option value="wr_subject||wr_content">제목+내용</option>
<option value="wr_name,1">글쓴이</option>
</select>
<input name="stx" class="stx" maxlength="15" itemname="검색어" required value='<?=stripslashes($stx)?>'>
<input type="image" src="<?=$board_skin_path?>/img/btn_search.gif" border='0' align="absmiddle">
</form>
</div>
<?*/?>
<div class="board_search">
<form method="get">
<input type="hidden" name="bo_table" value="<?=$bo_table?>" />
<input type="hidden" name="sop" value="and" />
<input type="hidden" name="sca" value="<?=$sca?>" />
<input type="hidden" name="sfl" id="sfl" value="<?=$sfl ? $sfl : "wr_subject||wr_content"?>" />

<div class="search_box">
<div class="search_option_box">
<div class="search_option">
<label id="search_option_selector">제목&amp;내용</label>
</div>
<ul id="search_option_list">
<li><label for="stx" class="wr_subject||wr_content">제목&amp;내용</label></li>
<li><label for="stx" class="wr_subject">제목</label></li>
<li><label for="stx" class="wr_content">내용</label></li>
<li><label for="stx" class="wr_name,1">글쓴이</label></li>
</ul>
</div>

<div id="search_input">
<input id="stx" name="stx" itemname="검색어" value="<?=stripslashes($stx)?>" />
</div>
</div>

<div id="search_submit">
<input src="<?=$board_skin_path?>/img/btn_search.gif" alt="검색" type="image">
</div>
</form>
</div>

<script type="text/javascript">
$("#search_option_selector").bind("click",function(){
$("#search_option_list").show();
return false;
});
$("#search_option_list").find("label").bind("click",function(){
$("#search_option_selector").text($(this).text());
$("#search_option_list").hide();
$("#sfl").val( $(this).attr("class"));
});
$("#search_submit input").mousedown(function(){
$(this).attr('src','<?=$board_skin_path?>/img/btn_search_down.gif');
});
$("#search_submit input").hover(function(){
$(this).attr('src','<?=$board_skin_path?>/img/btn_search_over.gif');
},function(){
$(this).attr('src','<?=$board_skin_path?>/img/btn_search.gif');
});
</script>

<script type="text/javascript">
if ('<?=$sca?>') $("#search_category").val("<?=$sca?>");
</script>

<? if ($is_checkbox) { ?>
<script type="text/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=500, height=550, scrollbars=1");

    f.sw.value = sw;
    f.target = "move";
    f.action = "./move.php";
    f.submit();
}
</script>
<? } ?>
</div>
<!-- .board_list end -->






그리고 하나 더 질문이요ㅠㅠ 제가 제로보드4를 어제까지 쓰다가 오늘부터 한 번 시험삼아 연습해보는건데, 제로보드 4는 노프레임으로 포토샵에서 디자인 후 슬라이스 쳐서 표로 나눠서 head.php foot.php로 나누잖아요. 그누보드 리뉴얼 할 때도 그렇게 해서 head.php tail.php로 저장해서 올리면 되는건가요?

댓글 전체

// 선택옵션으로 인해 셀합치기가 가변적으로 변함
$colspan = 5;
을 해당 숫자로 변경해주시고요 관리자 접속시 체크 버튼 뺀 갯수입니다


<colgroup>
<col width="50" />
<? if ($is_checkbox) { ?><col width="40" /><? } ?>
<col class="m_view" />
<col class="m_view" width="110" />
<col width="40" />
<col width="50" />
<? if ($is_good) { ?><col width="40" /><? } ?>
<? if ($is_nogood) { ?><col width="40" /><? } ?>
</colgroup>

부분 필요 없는내용 삭제해 주시고요


제목 부분

<th><span class="num">번호</span></th>
<? if ($is_checkbox) { ?><th><input onclick="if (this.checked) all_checked(true); else all_checked(false);" type="checkbox"></th><?}?>
<th class="m_view">제목</th>
<th class="m_view">글쓴이</th>
<th><?=subject_sort_link('wr_datetime', $qstr2, 1)?>작성일</a></th>
<th><?=subject_sort_link('wr_hit', $qstr2, 1)?>조회수</a></th>

에 필요 없는 내용 삭제 하시고요


마지막으로 글내용 나오는

<td class="name m_view"><?=$list[$i][name]?></td>
<td class="datetime"><?=$list[$i][datetime2]?></td>
<td class="hit"><?=$list[$i][wr_hit]?></td>
<? if ($is_good) { ?><td class="good"><?=$list[$i][wr_good]?></td><? } ?>
<? if ($is_nogood) { ?><td class="nogood"><?=$list[$i][wr_nogood]?></td><? } ?>

부분 필요 없는 부분 삭제해 주시면 됩니다


그리고 기본 레이어 구조를 아시고 계시면 작업하기 편하실것이니
http://sir.co.kr/manual/kcp_youngcart4/?man=page.htm

메뉴얼 부분에 구조 입니다 한눈에 보시기 편하실 것입니다
전체 66,554 |RSS
그누4 질문답변 내용 검색

회원로그인

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