코멘트 리스팅 되는데 이게 왜 위로 올라가지나요 ㅠ_ㅠ > 그누4 질문답변

그누4 질문답변

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

코멘트 리스팅 되는데 이게 왜 위로 올라가지나요 ㅠ_ㅠ 정보

코멘트 리스팅 되는데 이게 왜 위로 올라가지나요 ㅠ_ㅠ

본문

전진님의 답변으로 리스팅까진 성공했는데 이놈이 위로 올라가네요;;

코멘트 밑으로 위치시키려니깐 에러 나거나 댓글이 안보여요 ㅠ_ㅠ

좀만 도와주세요~

//소스

<? if ($bo_table == "4_5"){?>

<? // 코멘트 번호 계산식 및 페이징 표시
$c_total_count = count($list); // 전체 코멘트 수 할당
$c_rows = 5; // 보여줄 개수
if ($c_total_count != 0){
$c_total_page  = ceil($c_total_count / $c_rows);  // 전체 페이지 계산
if (!$c_page) $c_page = 1; // 페이지가 없으면 첫 페이지 (1 페이지)
$c_from_record = ($c_page - 1) * $c_rows; // 시작 코멘트 구하기
$c_last_record = $c_from_record + $c_rows; // 끝 코멘트 구하기
if($c_last_record > $c_total_count){ // 마지막 코멘트가 전체 코멘트 보다 크면 전체 코멘트로 할당
$c_last_record = $c_total_count;
}
}
// 페이징 처리 함수 및 표시
$c_pagelist = get_paging($c_rows, $c_page, $c_total_page, "./board.php?bo_table=$bo_table&wr_id=$wr_id&c_page=");
if ($c_pagelist) {
echo "<table width=100% cellpadding=3 cellspacing=1><tr><td align=center>$c_pagelist</td></tr></table>\n";
}
?>
<? // 코멘트 표시
$i = $c_from_record;
for ($i; $i<$c_last_record; $i++) {
$comment_id = $list[$i][wr_id];
?>

<a name="c_<?=$comment_id?>"></a>
<table border="0" cellspacing="0" cellpadding="0" style="margin-top:20px;">
<tr>
<td width="51" align="center"><?=$list[$i][wr_comment] ?></td>
<td width="51" align="center" colspan="2">
<img src="<?=$board_skin_path?>/img/sns_tw_s.jpg"  border="0">
<img src="<?=$board_skin_path?>/img/sns_fb_s.jpg"  border="0">
</td>
<td width="80" align="center" style="font-weight:bold;">[<?=$list[$i][wr_1]?>]개월</td>
<td width="309" style="padding-left:3px;"><?=$list[$i][content] ?></td>
<td width="90" align="center"><?=$list[$i][name]?> 님</td>
<td width="82" align="left"><?=date("y-m-d", strtotime($list[$i][wr_datetime]))?></td>
</tr>
<tr>
<td colspan="7" style="padding-top:10px; padding-bottom:10px;">
<img src="<?=$board_skin_path?>/img/comment_line.jpg"  border="0">
</td>
</tr>

</table>
<?
}
?>

댓글 전체

페이징 부분이, 댓글목록 위에 있네요 ^^;

// 페이징 처리 함수 및 표시
$c_pagelist = get_paging($c_rows, $c_page, $c_total_page, "./board.php?bo_table=$bo_table&wr_id=$wr_id&c_page=");
if ($c_pagelist) {
echo "<table width=100% cellpadding=3 cellspacing=1><tr><td align=center>$c_pagelist</td></tr></table>\n";
}

이 부분은, 맨 아래 ?> 바로 위로 올려보세요. ^^
전체 66,554 |RSS
그누4 질문답변 내용 검색

회원로그인

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