Пример #1
0
    $items = $ca['ca_mobile_list_mod'] * $ca['ca_mobile_list_row'];
    // 페이지가 없으면 첫 페이지 (1 페이지)
    if ($page < 1) {
        $page = 1;
    }
    // 시작 레코드 구함
    $from_record = ($page - 1) * $items;
    $list = new item_list($skin_file, $ca['ca_mobile_list_mod'], $ca['ca_mobile_list_row'], $ca['ca_mobile_img_width'], $ca['ca_mobile_img_height']);
    $list->set_category($ca['ca_id'], 1);
    $list->set_category($ca['ca_id'], 2);
    $list->set_category($ca['ca_id'], 3);
    $list->set_is_page(true);
    $list->set_mobile(true);
    $list->set_order_by($order_by);
    $list->set_from_record($from_record);
    $list->set_view('it_img', true);
    $list->set_view('it_id', false);
    $list->set_view('it_name', true);
    $list->set_view('it_price', true);
    echo $list->run();
    // where 된 전체 상품수
    $total_count = $list->total_count;
} else {
    echo '<div class="sct_nofile">' . str_replace(G5_PATH . '/', '', $skin_file) . ' 파일을 찾을 수 없습니다.<br>관리자에게 알려주시면 감사하겠습니다.</div>';
}
?>

    <?php 
if ($i > 0 && $total_count > $items) {
    $qstr1 .= 'ca_id=' . $ca_id;
    $qstr1 .= '&sort=' . $sort . '&sortodr=' . $sortodr;
Пример #2
0
    include G5_MSHOP_SKIN_PATH . '/list.sort.skin.php';
    // 총몇개 = 한줄에 몇개 * 몇줄
    $items = $ev['ev_mobile_list_mod'];
    // 페이지가 없으면 첫 페이지 (1 페이지)
    if ($page < 1) {
        $page = 1;
    }
    // 시작 레코드 구함
    $from_record = ($page - 1) * $items;
    $list = new item_list(G5_MSHOP_SKIN_PATH . '/' . $ev['ev_mobile_skin'], $ev['ev_mobile_list_mod'], 1, $ev['ev_mobile_img_width'], $ev['ev_mobile_img_height']);
    $list->set_event($ev['ev_id']);
    $list->set_is_page(true);
    $list->set_mobile(true);
    $list->set_order_by($order_by);
    $list->set_from_record($from_record);
    $list->set_view('it_img', true);
    $list->set_view('it_id', false);
    $list->set_view('it_name', true);
    $list->set_view('it_cust_price', false);
    $list->set_view('it_price', true);
    $list->set_view('it_icon', true);
    $list->set_view('sns', true);
    echo $list->run();
    // where 된 전체 상품수
    $total_count = $list->total_count;
    // 전체 페이지 계산
    $total_page = ceil($total_count / $items);
} else {
    echo '<div align="center">' . $ev['ev_mobile_skin'] . ' 파일을 찾을 수 없습니다.<br>관리자에게 알려주시면 감사하겠습니다.</div>';
}
?>
Пример #3
0
define('G5_SHOP_CSS_URL', str_replace(G5_PATH, G5_URL, $skin_dir));
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="' . G5_SHOP_CSS_URL . '/style.css">', 0);
?>

<h1 id="win_title">관련상품</h1>

<div class="sct_wrap">
    <?php 
$rel_skin_file = $skin_dir . '/' . $default['de_mobile_rel_list_skin'];
if (!is_file($rel_skin_file)) {
    $rel_skin_file = G5_MSHOP_SKIN_PATH . '/' . $default['de_mobile_rel_list_skin'];
}
$sql = " select b.* from {$g5['g5_shop_item_relation_table']} a left join {$g5['g5_shop_item_table']} b on (a.it_id2=b.it_id) where a.it_id = '{$it['it_id']}' and b.it_use='1' ";
$list = new item_list($rel_skin_file, 1, 1, $default['de_mobile_rel_img_width'], $default['de_mobile_rel_img_height']);
$list->set_mobile(true);
$list->set_query($sql);
$list->set_view('sns', true);
echo $list->run();
?>
</div>

<script>
$(function() {
    $("a.sct_a").on("click", function() {
        window.opener.location.href = this.href;
        self.close();
        return false;
    });
});
</script>