최신글 질문드려요
본문
안녕하세요 그누보드 5 이용자 입니다.
https://sir.kr/g5_skin/565?sfl=wr_subject&stx=%EC%8A%A4%ED%81%AC%EB%A1%A4
solsu1 님 이 잘만드어 주신 최신글 스킨을 사용 하고 있습니다.
게시물부분에 제가 댓글갯수와 조회수 갯수를 쓰고싶은데
$right_rolling .= "<li><div class=\"letiker\"><span class=\"subject\">ㆍ<a href=\"".$g5['url']."/bbs/board.php?bo_table=$temp[bo_table]&wr_id=$temp[wr_id]\">". cut_str($array_new['wr_subject'], $cur_subject) . "</a></span><span class=\"tikinfo\">" . $bo_name['bo_subject']. "<span class=\"tikbar\"> | </span>" . "</span></div><div class=\"ritiker\"><span class=\"timer\"></span>".$nr_datetime."</div>
</li>";
에
<span style='font:normal 12px Dotum; color:#999999;'>조회수 : </span>
<span style='font:normal 12px Dotum; color:#999999;'><?=$list[$i][wr_hit]?></span>
<span style='font:normal 10px Dotum; color:#DCDCDC;'> | </span>
<span style='font:normal 12px Dotum; color:#999999;'>댓글 : </span>
<span style='font:normal 12px tahoma; color:#CC7299;'><?=$list[$i][wr_comment]?></span>
을 합쳐 서 조회수밑 댓글 갯수를 같이 보고싶습니다 어떻게 해야할까요;;?
!-->!-->답변 1
상단에
$array_new = sql_fetch(" select wr_subject, wr_datetime, wr_name from ". $g4['write_prefix'].$temp[bo_table]. " where wr_id = '$temp[wr_id]'");
부분에 wr_hit, wr_comment 추가
$array_new = sql_fetch(" select wr_subject, wr_datetime, wr_name, wr_hit, wr_comment from ". $g4['write_prefix'].$temp[bo_table]. " where wr_id = '$temp[wr_id]'");
//wr_hit , wr_comment 추가
$right_rolling .= "<li><div class=\"letiker\"><span class=\"subject\">ㆍ<a href=\"".$g4['path']."/bbs/board.php?bo_table=$temp[bo_table]&wr_id=$temp[wr_id]\">". cut_str($array_new['wr_subject'], 36) . "</a></span><span class=\"tikinfo\">" . $bo_name['bo_subject']. "<span class=\"tikbar\"> | </span>" .$array_new['wr_name']. "<span class=\"tikbar\"> | </span>hit:".$array_new[wr_hit]."<span class=\"tikbar\"> | </span>c:".$array[wr_comment]."</span></div><div class=\"ritiker\"><span class=\"timer\"></span>".$nr_datetime."</div></li>";