다중 카테고리값을 ca_name에 담아서 가|나|다 일때 라테스트에서 추출어떻게 할까욤? 정보
다중 카테고리값을 ca_name에 담아서 가|나|다 일때 라테스트에서 추출어떻게 할까욤?본문
다중 카테고리값을 ca_name에 담아서 가|나|다 일때 라테스트에서 추출어떻게 할까욤?
latest.lib.php >> 에서요 $options' 값을 받아왔습니다~~
옵션값은 '가' 하나이지만 이게시판에 ca_name 값은 가|나|다 이러헥 있습니다~
여기서 가|나|다 값에 옵션값이 있는지 비교하여 있으면 latest로 보여주기 하면되는데요~~
고수님들 도와주세욤^^;; 그럼 대박나시길 바라겠습니다~
$sql = " select * from $tmp_write_table where wr_is_comment = 0 and ca_name='$options' order by wr_last desc limit 0, $rows ";
//explain($sql);
$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;
latest.lib.php >> 에서요 $options' 값을 받아왔습니다~~
옵션값은 '가' 하나이지만 이게시판에 ca_name 값은 가|나|다 이러헥 있습니다~
여기서 가|나|다 값에 옵션값이 있는지 비교하여 있으면 latest로 보여주기 하면되는데요~~
고수님들 도와주세욤^^;; 그럼 대박나시길 바라겠습니다~
$sql = " select * from $tmp_write_table where wr_is_comment = 0 and ca_name='$options' order by wr_last desc limit 0, $rows ";
//explain($sql);
$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;
댓글 전체
무슨 질문인지 이해가 안되요 ㅠ
최신글 추출할때 게시물당 카테고리는 list[$i]['ca_name']에 있습니다.
최신글 추출할때 게시물당 카테고리는 list[$i]['ca_name']에 있습니다.
list[$i]['ca_name'] 그값이 하나가 아니라 가|나|다 여러개 들어가있을때요~~