diff --git a/lib/shop.lib.php b/lib/shop.lib.php index 52b3ad451..f84e0178a 100644 --- a/lib/shop.lib.php +++ b/lib/shop.lib.php @@ -1117,11 +1117,17 @@ function display_banner($position, $skin='') if (!$position) $position = '왼쪽'; if (!$skin) $skin = 'boxbanner.skin.php'; - // 배너 출력 - $sql = " select * from {$g5['g5_shop_banner_table']} where '".G5_TIME_YMDHIS."' between bn_begin_time and bn_end_time and bn_position = '$position' order by bn_order, bn_id desc "; - $result = sql_query($sql); + $skin_path = G5_SHOP_SKIN_PATH.'/'.$skin; - include G5_SHOP_SKIN_PATH.'/boxbanner'.$num.'.skin.php'; + if(file_exists($skin_path)) { + // 배너 출력 + $sql = " select * from {$g5['g5_shop_banner_table']} where '".G5_TIME_YMDHIS."' between bn_begin_time and bn_end_time and bn_position = '$position' order by bn_order, bn_id desc "; + $result = sql_query($sql); + + include $skin_path; + } else { + echo '

'.str_replace(G5_PATH.'/', '', $skin_path).'파일이 존재하지 않습니다.

'; + } } diff --git a/skin/shop/basic/mainbanner.10.skin.php b/skin/shop/basic/mainbanner.10.skin.php index b5ff0b98a..896b69973 100644 --- a/skin/shop/basic/mainbanner.10.skin.php +++ b/skin/shop/basic/mainbanner.10.skin.php @@ -6,9 +6,12 @@ add_stylesheet('', ?>

쇼핑몰 배너

'.PHP_EOL.''.PHP_EOL; +?> + + \ No newline at end of file diff --git a/skin/shop/basic/style.css b/skin/shop/basic/style.css index 6c8682128..b8a9203d7 100644 --- a/skin/shop/basic/style.css +++ b/skin/shop/basic/style.css @@ -58,6 +58,13 @@ .sbn li {margin:0 0 1px} .sbn .sbn_border {border:1px solid #d5d5d5} /* 인덱스 배너도 함께 사용 */ +#sbn_idx ul {position:relative;overflow:hidden} +#sbn_idx ul li {position:absolute;display:none;top:0;left:0} +#sbn_idx ul li.sbn_first{display:block} +#sbn_idx button {position:absolute;top:100px;z-index:100} +#sbn_idx #sbn_btn_prev{left:50px} +#sbn_idx #sbn_btn_next{right:50px} + /* aside:장바구니 */ #sbsk {margin:0 0 5px;padding:0 0 10px;border:1px solid #d5d5d5;background:#f2f5f9} #sbsk h2 {position:absolute;font-size:0;line-height:0;overflow:hidden}