그룹리스트 페이지 문제입니다..ㅡㅜ > 그누4 질문답변

그누4 질문답변

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

그룹리스트 페이지 문제입니다..ㅡㅜ 정보

그룹리스트 페이지 문제입니다..ㅡㅜ

본문

latest_group로 해서  게시판 리스트 처럼 만들어 보았습니다
그런데 페이징을 하려고 한데...오류가 나는 것도 아니고
페이징이 보이지 않습니다..ㅡㅜ
썸네일로 첨부파일과 에디터 이미지를 구분해서 불러온다고
이거저거 하다가 그룹최신글 스킨을 보통 게시판 스킨을 썼습니다...
그래서 그게 문제인지...페이징이 되지 않습니다....
ㅠㅠ 어떻게 하면 좋을까여...ㅠㅠ

소스는 이것을입니다...머가 문제 일까여..ㅠㅠ
<?
$image_height = 85; // 높이
$image_width  = 125; // 너비
?>
<meta name="generator" content="Namo WebEditor(Trial)">
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
include_once("$g4[path]/lib/thumb.lib.php");
include_once("$g4[path]/bbs/list.php");
// 선택옵션으로 인해 셀합치기가 가변적으로 변함
$colspan = 4;

$mod = $board[bo_gallery_cols];  //
// 썸네일 생성
$thumb_width = "125"; //썸네일 가로길이 / 이미지 크기를 조정하실려면 조정하십시오.
$thumb_height = "85"; //썸네일 세로길이
$thumb_quality = "100"; //퀼리티 100이하로 설정
$wr_content_cut = "300";  //본문글자 자를숫자

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

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


$is_name = true;
$is_date = true;

if ($bo_table=='g4_pds' || $bo_table=='faq' || $bo_table=='yc_faq' || $bo_table=='co_notice') $is_name = false;
if ($bo_table=='faq') $is_date = false;

//if ($is_category) $colspan++;
if ($is_checkbox) $colspan++;
if ($is_name) $colspan++;
if ($is_date) $colspan++;
if ($is_good) $colspan++;
if ($is_nogood) $colspan++;

// 제목이 두줄로 표시되는 경우 이 코드를 사용해 보세요.
// <nobr style='display:block; overflow:hidden; width:000px;'>제목</nobr>
?>
<?
$rows = $config[cf_new_rows];
$total_page  = ceil($total_count / $rows);  // 전체 페이지 계산
if (!$page) $page = 1; // 페이지가 없으면 첫 페이지 (1 페이지)
$from_record = ($page - 1) * $rows; // 시작 열을 구함
?>
<!-- 게시판 목록 시작 -->
<table width="<?=$width?>" align=center cellpadding=0 cellspacing=0>
<tr>
<td>




<? if ($rss_href) { ?><a href='<?=$rss_href?>'><img src='<?=$board_skin_path?>/img/btn_rss.gif' border=0 align=absmiddle></a><?}?>
<? 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><? }?>

</table>

<!-- 제목
<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=''>-->

<table width=100% border="0" cellpadding=0 cellspacing="2">



<!-- 목록 -->
<? for ($i=0; $i<count($list); $i++) { ?>
<tr height=28 align=center>
 
        <?
        if ($list[$i][is_notice]) // 공지사항
            echo "<img src=\"$board_skin_path/img/icon_notice.gif\">";
        else if ($wr_id == $list[$i][wr_id]) // 현재위치
            echo "<span style='font:bold 11px tahoma; color:#E15916;'>{$list[$i][num]}</span>";
        else
            echo "<span style='font:normal 11px tahoma; color:#BABABA;'>{$list[$i][num]}</span>";
        ?>
   

<!--이미지 시작-->
<td align="center"><?
$img = "<img src='$board_skin_path/img/no_img.gif' border=0 title='이미지 없음'>";
//$thumb = $thumb_path.'/'.$list[$i][wr_id];

$phone = $list[$i]['wr_content'];

if (eregi("<img [^<>]*>", $phone, $regs)) { // img src="images/xxx.gif" 까지 추출

    $tmp_str = $regs[0];
    eregi("[^= \"']*\.(gif|jpg|png|bmp)", $tmp_str, $regs1);  // images/xxx.gif 까지 추출
    $tmp1_str = $regs1[0];
    eregi("[^= '/]*\.(gif|jpg|png|bmp)", $tmp1_str, $regs2); // xxx.gif 까지 추출

    $filename = $regs2[0]; // 파일명

} else {

    $filename = "";

}

// 파일
if ($list[$i][file][0][file]) {

    // 썸네일
    $thumb = $thumb_path.'/'.$list[$i][file][0][file];

} else {

    // 썸네일
    $thumb = $thumb_path.'/'.$filename;

}

// 썸네일이 없다면
if (!file_exists($thumb)) {

    // 파일
    if ($list[$i][file][0][file]) {

        // 원본
        $thumb_file = $list[$i][file][0][path] .'/'. $list[$i][file][0][file];

    } else {

        // 날짜별 폴더 지정
        $thumb_date = date("Ym", strtotime($list[$i]['wr_datetime']));
        $date_url = substr($thumb_date,2,5);
        $data_path = "{$g4['path']}/data/cheditor/{$date_url}";

        // 원본
        $thumb_file = $data_path.'/'.$filename;

    }

    // 확장자 체크
    if (preg_match("/\.(jp[e]?g|gif|png)$/i", $thumb_file) && file_exists($thumb_file)) {

        createThumb($thumb_width, $thumb_height, $thumb_file, $thumb, true);

    }

}

if (file_exists($thumb)) {

    echo "<a href='{$list[$i][href]}'><img src='{$thumb}' width='125' height='85' align='absmiddle' border='0'></a>";

} else {

    echo "";

}
?></td>
    <td width="5"></td>
<td>
<table width="100%">
<tr>
<td align=left style='word-break:break-all;'>
        <?
        echo $nobr_begin;
        echo $list[$i][reply];
        echo $list[$i][icon_reply];
        if ($is_category && $list[$i][ca_name]) {
            echo "<span class=small><font color=gray>[<a href='{$list[$i][ca_name_href]}'>{$list[$i][ca_name]}</a>]</font></span> ";
        }
        $style = "";
        if ($list[$i][is_notice]) $style = " style='font-weight:bold;'";

        echo "<b><a href='{$list[$i][href]}'> <font style='font-family:&micro;&cedil;&iquest;&ograve;; font-size:9pt; color:#000000;'><strong>";
        echo $list[$i][subject];
        echo "</strong></font></a></b>";
       
      ?>
  <a href='<?=$list[$i][href]?>' class='txtlightgray12'>
    <img src="<?=$g4[path]?>/img/more2.gif" width="52" height="11" border="0" align="absmiddle"></a>
  </td>
  </tr>
  <tr>
  <td>
        <?
$wr_content = "<a href='{$list[$i][href]}' $style><font style='font-family:돋움; font-size:10pt; color:#6A6A6A;'>".cut_str(strip_tags($list[$i]['wr_content']), $wr_content_cut, '...')."</font></a>";
echo $wr_content ;
        ?></td>
  </tr>
  </table>
  </td>
  <tr>
  <td height='10' colspan="3"></td>
  </tr>
<? }?>

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

</table>
</form>

<!-- 페이지 -->
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
    <td width="100%" align="center" height=30 valign=bottom>
        <? if ($prev_part_href) { echo "<a href='$prev_part_href'><img src='$board_skin_path/img/btn_search_prev.gif' 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>/", "<b><font style=\"font-family:tahoma; font-size:11px; color:#000000\">$1</font></b>", $write_pages);
        $write_pages = preg_replace("/<b>([0-9]*)<\/b>/", "<b><font style=\"font-family:tahoma; font-size:11px; color:#E15916;\">$1</font></b>", $write_pages);
        ?>
        <?=$write_pages?>
        <? if ($next_part_href) { echo "<a href='$next_part_href'><img src='$board_skin_path/img/btn_search_next.gif' border=0 align=absmiddle title='다음검색'></a>"; } ?>
    </td>
</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>
  • 복사

댓글 전체

© SIRSOFT
현재 페이지 제일 처음으로