|
|
|
16년 전
|
조회 1,553
|
|
|
|
16년 전
|
조회 1,059
|
|
|
|
16년 전
|
조회 1,346
|
|
|
|
16년 전
|
조회 1,022
|
|
|
|
16년 전
|
조회 3,355
|
|
|
|
16년 전
|
조회 985
|
|
|
|
16년 전
|
조회 1,223
|
|
|
|
16년 전
|
조회 1,644
|
|
|
|
16년 전
|
조회 1,596
|
|
|
|
16년 전
|
조회 2,148
|
|
|
|
16년 전
|
조회 1,079
|
|
|
|
16년 전
|
조회 1,405
|
|
|
|
16년 전
|
조회 1,455
|
|
|
|
16년 전
|
조회 924
|
|
|
|
16년 전
|
조회 1,232
|
|
|
|
16년 전
|
조회 1,547
|
|
|
|
16년 전
|
조회 1,103
|
|
|
|
16년 전
|
조회 838
|
|
|
|
16년 전
|
조회 963
|
|
|
|
16년 전
|
조회 945
|
댓글 4개
// 최신글 추출
function latest2($skin_dir="", $bo_table, $rows=10, $subject_len=40, $options="")
{
global $g4;
if ($skin_dir)
$latest_skin_path = "$g4[path]/skin/latest/$skin_dir";
else
$latest_skin_path = "$g4[path]/skin/latest/basic";
$list = array();
$sql = " select * from $g4[board_table] where bo_table = '$bo_table'";
$board = sql_fetch($sql);
$tmp_write_table = $g4['write_prefix'] . $bo_table; // 게시판 테이블 전체이름
$sql = " select * from $tmp_write_table where wr_is_comment = 0 and ca_name != '카테고리제외' order by wr_num limit 0, $rows ";
$result = sql_query($sql);
for ($i=0; $row = sql_fetch_array($result); $i++)
$list[$i] = get_list($row, $board, $latest_skin_path, $subject_len);
ob_start();
include "$latest_skin_path/latest.skin.php";
$content = ob_get_contents();
ob_end_clean();
return $content;
}
이런식으로 사용하시면 될듯합니다.
잘 지내시지요?
건강하세요
쿼리의 자원 남용을 막는 차원에서 함수를 수정하는 걸로 적어 드렸습니다.^^