답변 1개
채택된 답변
+20 포인트
9년 전
</p><p><?php </p><p>$sql = "<span class="cm-keyword" style="color: rgb(119, 0, 136); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"><a target="mysql_doc" class="cm-sql-doc" href="<a href="http://localhost/phpmyadmin/url.php?url=http://dev.mysql.com/doc/refman/5.5/en/select.html" target="_blank" rel="noopener noreferrer">http://localhost/phpmyadmin/url.php?url=http://dev.mysql.com/doc/refman/5.5/en/select.html</a>" style="text-decoration: none; color: rgb(35, 90, 129); cursor: pointer; outline: none; border-bottom: 1px dotted rgb(0, 0, 0);">SELECT</a></span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">gr_id</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">,</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span class="cm-keyword" style="color: rgb(119, 0, 136); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"><a target="mysql_doc" class="cm-sql-doc" href="<a href="http://localhost/phpmyadmin/url.php?url=http://dev.mysql.com/doc/refman/5.5/en/group-by-functions.html#function_sum" target="_blank" rel="noopener noreferrer">http://localhost/phpmyadmin/url.php?url=http://dev.mysql.com/doc/refman/5.5/en/group-by-functions.html#function_sum</a>" style="text-decoration: none; color: rgb(35, 90, 129); cursor: pointer; outline: none; border-bottom: 1px dotted rgb(0, 0, 0);">SUM</a></span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">(</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">bo_count_write</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">) as cnt</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span class="cm-keyword" style="color: rgb(119, 0, 136); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">FROM</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span class="cm-variable-2" style="color: rgb(0, 85, 170); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">`g5_board`</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span class="cm-keyword" style="color: rgb(119, 0, 136); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">group</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span class="cm-keyword" style="color: rgb(119, 0, 136); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">by</span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);"> </span><span style="color: rgb(68, 68, 68); font-family: monospace; font-size: 10.66px; background-color: rgb(229, 229, 229);">gr_id</span><span style="font-size: 11pt;">";</span></p><p><span style="font-size: 11pt;">$gr_cnt_list = sql_query($sql);</span></p><p>while($row = sql_fetch_array($gr_cnt_list)){?></p><p> </p><p><a href="<?php echo $row['gr_id']?>"><?php echo <span style="font-size: 14.6667px;">$row['gr_id'].$row['cnt']?><a></span></p><p><?php }?></p><p>
이렇게 하면 되지 않을까 싶습니다.
확인은 안해봤습니다ㅎㅎ;
로그인 후 평가할 수 있습니다
답변에 대한 댓글 1개
�
9년 전
댓글을 작성하려면 로그인이 필요합니다.
답변을 작성하려면 로그인이 필요합니다.
로그인전체 질문 목록
답변대기
답변대기
답변대기
답변대기
답변대기
답변대기
답변대기
답변대기
채택
답변대기
답변대기
답변대기
답변대기
채택
채택
답변대기
답변대기
답변대기
채택
이대로 해보앗지만 그룹 게시물은 나오지만 그룹메뉴가 반복으로 나오군 합니다 ...
ㅠㅠ