[최신글 다중 추출] 재문의 드립니다

[최신글 다중 추출] 재문의 드립니다

QA

[최신글 다중 추출] 재문의 드립니다

본문

이전 질문 : http://sir.co.kr/qa/?wr_id=5220&page=1&sfl=&stx=&sst=&page=1&unanswered=0&s_tag=&cwin=&vsst=old&vpage=1#c_5251



오류가 출력되는 사이트 : http://test.withlcc.com/

select wr_content from g5_write_ where wr_id = '1'

1146 : Table 'lovedb2.g5_write_' doesn't exist

error file : /index.php



lib 소스
function xe_latest_multi($skin_dir='', $bo_table1, $bo_table2, $bo_table3, $rows=10, $subject_len=40)
{
    global $g5, $xe;
    static $css = array();

    if (!$skin_dir) $skin_dir = 'xe_basic';

$latest_skin_path = XE_SKIN_PATH.'/latest/'.$skin_dir;
$latest_skin_url  = XE_SKIN_URL.'/latest/'.$skin_dir;

    $cache_file = G5_DATA_PATH."/cache/latest-{$bo_table}-{$skin_dir}-{$rows}-{$subject_len}.php";
    if (!G5_USE_CACHE || !file_exists($cache_file)) {
        $list = array();

$sql = " select * from $g5[board_new_table] a, $g5[board_table] b where a.bo_table = b.bo_table and a.bo_table in('$bo_table1', '$bo_table2', '$bo_table3') and a.wr_id = a.wr_parent order by a.bn_id desc limit $rows ";
$result = sql_query($sql);


        for ($i=0; $board = sql_fetch_array($result); $i++) {

$tmp_write_table = $g5['write_prefix'] . $board[bo_table]; // 게시판 테이블 전체이름

$sql = " select * from $tmp_write_table where wr_id = '$board[wr_id]' ";
$result2 = sql_query($sql);
$row2 = sql_fetch_array($result2);

$list[$i] = get_list($row2, $board, $latest_skin_url, $subject_len);
$list[$i][bo_table] = $board[bo_table];
$bo_table = $list[$i][bo_table];
        }

        $handle = fopen($cache_file, 'w');
$cache_content = "<?php\nif (!defined('_GNUBOARD_')) exit;\n\$bo_subject=\"".get_text($board['bo_subject'])."\";\n\$list=".var_export($list, true)."?>";
        fwrite($handle, $cache_content);
        fclose($handle);
    }

include_once($cache_file);

    ob_start();
    include $latest_skin_path.'/latest.skin.php';
    $content = ob_get_contents();
    ob_end_clean();

    return $content;

}



스킨

<div class="xe_latest_04">
<div class="title"><a href="<?php echo G5_BBS_URL ?>/board.php?bo_table=<?php echo $bo_table ?>"><?php echo $bo_subject; ?></a></div>
<ul>


부라우저에서 HTML 소스보기를 해보니

하단에 스킨부분에 /board.php?bo_table=<?php echo $bo_table ?> 여기에 우선 $bo_table 값에 관리자페이지에서 캐쉬삭제를 하면 한번은 넘어 오는데, 다시 리푸레쉬하면 또 오류가 발생하고 값이 안넘어 오네요 ;;

요가 가지고 몇일째 ;;

이 질문에 댓글 쓰기 :

답변을 작성하시기 전에 로그인 해주세요.
전체 59,604
QA 내용 검색

회원로그인

(주)에스아이알소프트 / 대표:홍석명 / (06211) 서울특별시 강남구 역삼동 707-34 한신인터밸리24 서관 1404호 / E-Mail: admin@sir.kr
사업자등록번호: 217-81-36347 / 통신판매업신고번호:2014-서울강남-02098호 / 개인정보보호책임자:김민섭(minsup@sir.kr)
© SIRSOFT