메인탭에 공지사항글을 항상 출력하게하려면?! > 그누4 질문답변

그누4 질문답변

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

메인탭에 공지사항글을 항상 출력하게하려면?! 정보

메인탭에 공지사항글을 항상 출력하게하려면?!

본문

안녕하세요?
알림방 탭게시판에 공지사항 글이 항상 첫번째로 있어야하는데
새글이 올라오면 계속 밀리네요.
http://asanrehab.or.kr/


<?=latest("plip_last", asan_0506, 6, 40,"/sub05/communisty_02.html");?><!--<?//=latest_notice("plip_last_notice", asan_0506, 6, 40,"/sub05/communisty_02.html")//공지목록나오게 하려면 이 최근게시물을 사용해주세요?>-->

↑ 메인에 뿌려진 탭메뉴 소스구요





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

?>
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td height='4'></td>
</tr>
<? for ($i=0; $i<count($list); $i++) { ?>
<tr>
    <td>
        <table width="100%" cellpadding="4" cellspacing="0">
<tr>

            <td align='left'>
            <?
            echo $list[$i]['icon_reply'] . " ";
            echo "<a href='{$options}?wr_id={$list[$i][wr_id]}' >";
            if ($list[$i]['is_notice'])
                echo "<font style='font-family:돋움; font-size:9pt; color:#1B75A5;'><strong>{$list[$i]['subject']}</strong></font>";
            else
                echo "<font style='font-family:돋움; font-size:9pt;'>{$list[$i]['subject']}</font>";
            echo "</a>";

            if ($list[$i]['comment_cnt'])
                echo " <a href=\"{$list[$i]['comment_href']}\"><span style='font-family:돋움; font-size:8pt; color:#9A9A9A;'>{$list[$i]['comment_cnt']}</span></a>";

            // if ($list[$i]['link']['count']) { echo "[{$list[$i]['link']['count']}]"; }
            // if ($list[$i]['file']['count']) { echo "<{$list[$i]['file']['count']}>"; }
echo " " . $list[$i]['icon_new'];
            ?>
</td>
<td width='78'><? echo "<font style='font-family:돋움; font-size:9pt; color:#05496D;'>[";
echo date("Y-m-d",strtotime($list[$i][wr_datetime]));
echo "]</font>";
?>
</td>           
</tr>
       
        </table></td>
</tr>
<tr>
  <td height="1" background="<?=$latest_skin_path?>/img/dot.gif"><img src="<?=$latest_skin_path?>/img/dot.gif" width="4" height="1"></td>
</tr>
<? } ?>
<? if(is_array($list2)){?>
<? for ($i=0; $i<count($list2); $i++){ ?>
<tr>
    <td>
        <table width="100%" cellpadding="4" cellspacing="0">
<tr>

            <td align='left'>
            <?
echo "<a href='{$options}?wr_id={$list[$i][wr_id]}' >";
            echo $list2[$i]['icon_reply'] . " ";
         
            if ($list2[$i]['is_notice'])
                echo "<font style='font-family:돋움; font-size:9pt; color:#1B75A5;'><strong>{$list2[$i]['subject']}</strong></font>";
            else
                echo "<font style='font-family:돋움; font-size:9pt;'>{$list2[$i]['subject']}</font>";
            echo "</a>";

            if ($list2[$i]['comment_cnt'])
                echo " <a href=\"{$list2[$i]['comment_href']}\"><span style='font-family:돋움; font-size:8pt; color:#9A9A9A;'>{$list2[$i]['comment_cnt']}</span></a>";

            // if ($list[$i]['link']['count']) { echo "[{$list[$i]['link']['count']}]"; }
            // if ($list[$i]['file']['count']) { echo "<{$list[$i]['file']['count']}>"; }
echo " " . $list2[$i]['icon_new'];
            ?>
</td>
<td width='78'><? echo "<font style='font-family:돋움; font-size:9pt; color:#05496D;'>[";
echo date("Y-m-d",strtotime($list2[$i][wr_datetime]));
echo "]</font>";
?>
</td>           
</tr>
        </table></td>
</tr>
<tr>
  <td height="1" colspan="2" background="<?=$latest_skin_path?>/img/dot.gif"><img src="<?=$latest_skin_path?>/img/dot.gif" width="4" height="1"></td>
</tr>
<? } ?>
<?}?>

<? if (count($list) == 0) { ?><tr><td align=center height=50><font color=#6A6A6A>게시물이 없습니다.</font></td></tr><? } ?>

</table>

↑latest 스킨입니다.


공지사항글이 항상 출력되는 방법이 없을까요?

그누보드를 처음 시작하는 초짜인지라
간단한 방법이 있는데도 못 찾는 것인지,
아님 따로 파일을 수정해야 하는건지 잘 모르겠어요.
답변 부탁드릴게요.
  • 복사

댓글 전체

스킨에서 조절할 수 있는 성질이 아닙니다
latest() 함수에서 테이블 내용을 추출할 때 공지를 먼저 추출해서 $list 만들고
공지를 제외한 나머지를 추출해서 $list를 만들고 좀 복잡하군요
© SIRSOFT
현재 페이지 제일 처음으로