1:1문의를 최신글로 출력해보기
<?php
$qa_latest_skin_url = G5_THEME_URL."/skin/latest/basic/"; //테마를 사용하며 최신글 베이직 스킨을 사용할때의 경로
add_stylesheet('<link rel="stylesheet" href="'.$qa_latest_skin_url.'/style.css">', 0); //스타일시트를 적용
$rows = "5"; // 출력시킬 최신글 갯수
$sql = " select * from {$g5['qa_content_table']} where qa_type = 0 order by qa_id desc limit 0, {$rows} ";
$result = sql_query($sql);
?>
<div class="lt">
<strong class="lt_title"><a href="<?php echo G5_BBS_URL ?>/qalist.php">1:1문의</a></strong>
<ul>
<?php for ($i=0; $row = sql_fetch_array($result); $i++) {
// 오늘을 불러옵니다.
$intime = date("Y-m-d H:i:s", time() - (int)(60 * 60 * 24)); ?>
<li>
<a href="<?php echo G5_BBS_URL ?>/qaview.php?qa_id=<?php echo $row[qa_id];?>">
<?php echo $row[qa_subject];
if($row[qa_datetime] >= $intime) echo " <img src=".$qa_latest_skin_url."img/icon_new.gif";
//24시간 이내에 등록된 게시물은 new 아이콘 출력 시키기
?>
</a>
</li>
<?php } ?>
<?php if (count($result) == 0) { //게시물이 없을 때 ?>
<li>게시물이 없습니다.</li>
<?php } ?>
</ul>
<div class="lt_more"><a href="<?php echo G5_BBS_URL ?>/qalist.php"><span class="sound_only">1:1문의</span>더보기</a></div>
</div>
$qa_latest_skin_url = G5_THEME_URL."/skin/latest/basic/"; //테마를 사용하며 최신글 베이직 스킨을 사용할때의 경로
add_stylesheet('<link rel="stylesheet" href="'.$qa_latest_skin_url.'/style.css">', 0); //스타일시트를 적용
$rows = "5"; // 출력시킬 최신글 갯수
$sql = " select * from {$g5['qa_content_table']} where qa_type = 0 order by qa_id desc limit 0, {$rows} ";
$result = sql_query($sql);
?>
<div class="lt">
<strong class="lt_title"><a href="<?php echo G5_BBS_URL ?>/qalist.php">1:1문의</a></strong>
<ul>
<?php for ($i=0; $row = sql_fetch_array($result); $i++) {
// 오늘을 불러옵니다.
$intime = date("Y-m-d H:i:s", time() - (int)(60 * 60 * 24)); ?>
<li>
<a href="<?php echo G5_BBS_URL ?>/qaview.php?qa_id=<?php echo $row[qa_id];?>">
<?php echo $row[qa_subject];
if($row[qa_datetime] >= $intime) echo " <img src=".$qa_latest_skin_url."img/icon_new.gif";
//24시간 이내에 등록된 게시물은 new 아이콘 출력 시키기
?>
</a>
</li>
<?php } ?>
<?php if (count($result) == 0) { //게시물이 없을 때 ?>
<li>게시물이 없습니다.</li>
<?php } ?>
</ul>
<div class="lt_more"><a href="<?php echo G5_BBS_URL ?>/qalist.php"><span class="sound_only">1:1문의</span>더보기</a></div>
</div>
게시판 목록
그누보드5 팁자료실
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 공지 | 3년 전 | 4409 | ||
| 504 | 9년 전 | 8212 | ||
| 503 | 9년 전 | 5957 | ||
| 502 | 10년 전 | 13127 | ||
| 501 | 10년 전 | 8967 | ||
| 500 | 10년 전 | 8108 | ||
| 499 | 10년 전 | 24083 | ||
| 498 | 10년 전 | 7360 | ||
| 497 | 10년 전 | 9314 | ||
| 496 | 10년 전 | 12533 | ||
| 495 | 10년 전 | 6833 | ||
| 494 |
|
10년 전 | 6618 | |
| 493 | 10년 전 | 12655 | ||
| 492 | 10년 전 | 11278 | ||
| 491 |
고등동물고등어
|
10년 전 | 10617 | |
| 490 | 10년 전 | 9495 | ||
| 489 | 10년 전 | 16204 | ||
| 488 |
saesini
|
10년 전 | 8631 | |
| 487 | 10년 전 | 14356 | ||
| 486 | 10년 전 | 8059 | ||
| 485 | 10년 전 | 9633 | ||
| 484 |
|
10년 전 | 6703 | |
| 483 |
untitled
|
10년 전 | 9983 | |
| 482 | 10년 전 | 8278 | ||
| 481 | 10년 전 | 16276 | ||
| 480 | 10년 전 | 10372 | ||
| 479 |
|
10년 전 | 8104 | |
| 478 | 10년 전 | 12751 | ||
| 477 | 10년 전 | 6361 | ||
| 476 | 10년 전 | 8344 | ||
| 475 |
wonilone
|
10년 전 | 7319 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기