영카트 5.4 버전 내용 적용
@ -1,4 +1,4 @@
|
||||
<?php
|
||||
<?php
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
@ -41,9 +41,8 @@ if ($i>0) echo '</ul></aside>'.PHP_EOL;
|
||||
$(document).ready(function(){
|
||||
$('.sb_bn').show().bxSlider({
|
||||
speed:800,
|
||||
pager:false,
|
||||
pager:true,
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@ -3,11 +3,12 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
$cart_action_url = G5_SHOP_URL.'/cartupdate.php';
|
||||
?>
|
||||
|
||||
<!-- 장바구니 간략 보기 시작 { -->
|
||||
<aside id="sbsk" class="op_area">
|
||||
<h2>장바구니</h2>
|
||||
<aside id="sbsk" class="sbsk">
|
||||
<h2 class="s_h2">장바구니 <span class="cart-count"><?php echo get_boxcart_datas_count(); ?></span></h2>
|
||||
<form name="skin_frmcartlist" id="skin_sod_bsk_list" method="post" action="<?php echo G5_SHOP_URL.'/cartupdate.php'; ?>">
|
||||
<ul>
|
||||
<?php
|
||||
@ -20,15 +21,21 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
echo '<li>';
|
||||
$it_name = get_text($row['it_name']);
|
||||
// 이미지로 할 경우
|
||||
$it_img = get_it_image($row['it_id'], 60, 60, true);
|
||||
echo '<a href="'.G5_SHOP_URL.'/cart.php">'.$it_name.'</a>';
|
||||
echo '<div class="prd_img">'.$it_img.'</div>';
|
||||
$it_img = get_it_image($row['it_id'], 65, 65, true);
|
||||
echo '<div class="prd_img">'.$it_img.'</div>';
|
||||
echo '<div class="prd_cnt">';
|
||||
echo '<a href="'.G5_SHOP_URL.'/cart.php" class="prd_name">'.$it_name.'</a>';
|
||||
echo '<span class="prd_cost">';
|
||||
echo number_format($row['ct_price']).PHP_EOL;
|
||||
echo '</span>'.PHP_EOL;
|
||||
echo '</div>';
|
||||
echo '<button class="cart_del" type="button" data-it_id="'.$row['it_id'].'"><i class="fa fa-trash-o" aria-hidden="true"></i><span class="sound_only">삭제</span></button>'.PHP_EOL;
|
||||
echo '</li>';
|
||||
|
||||
echo '<input type="hidden" name="act" value="buy" >';
|
||||
echo '<input type="hidden" name="ct_chk['.$i.']" value="1" >';
|
||||
echo '<input type="hidden" name="act" value="buy">';
|
||||
echo '<input type="hidden" name="ct_chk['.$i.']" value="1">';
|
||||
echo '<input type="hidden" name="it_id['.$i.']" value="'.$row['it_id'].'">';
|
||||
echo '<input type="hidden" name="it_name['.$i.']" value="'.$it_name.'">';
|
||||
echo '<input type="hidden" name="it_name['.$i.']" value="'.$it_name.'">';
|
||||
|
||||
$i++;
|
||||
} //end foreach
|
||||
@ -37,9 +44,39 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
echo '<li class="li_empty">장바구니 상품 없음</li>'.PHP_EOL;
|
||||
?>
|
||||
</ul>
|
||||
<?php if($i){ ?><button type="submit" class="btn02 btn_buy"><i class="fa fa-credit-card" aria-hidden="true"></i> 바로구매</button><?php } ?>
|
||||
<a href="<?php echo G5_SHOP_URL; ?>/cart.php" class="btn01 go_cart">장바구니 바로가기</a>
|
||||
<?php if($i){ ?><div class="btn_buy"><button type="submit" class="btn_submit">구매하기</button></div><?php } ?>
|
||||
<a href="<?php echo G5_SHOP_URL; ?>/cart.php" class="go_cart">전체보기</a>
|
||||
</form>
|
||||
</aside>
|
||||
<script>
|
||||
jQuery(function ($) {
|
||||
$("#sbsk").on("click", ".cart_del", function(e) {
|
||||
e.preventDefault();
|
||||
|
||||
var it_id = $(this).data("it_id");
|
||||
var $wrap = $(this).closest("li");
|
||||
|
||||
$.ajax({
|
||||
url: g5_theme_shop_url+"/ajax.action.php",
|
||||
type: "POST",
|
||||
data: {
|
||||
"it_id" : it_id,
|
||||
"action" : "cart_delete"
|
||||
},
|
||||
dataType: "json",
|
||||
async: true,
|
||||
cache: false,
|
||||
success: function(data, textStatus) {
|
||||
if(data.error != "") {
|
||||
alert(data.error);
|
||||
return false;
|
||||
}
|
||||
|
||||
$wrap.remove();
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<!-- } 장바구니 간략 보기 끝 -->
|
||||
|
||||
|
||||
@ -3,39 +3,42 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
$mshop_categories = get_shop_category_array(true);
|
||||
?>
|
||||
|
||||
<!-- 쇼핑몰 카테고리 시작 { -->
|
||||
<nav id="gnb">
|
||||
<h2>쇼핑몰 카테고리</h2>
|
||||
<button type="button" id="menu_open"><i class="fa fa-bars" aria-hidden="true"></i> 카테고리</button>
|
||||
<ul id="gnb_1dul">
|
||||
<?php
|
||||
// 1단계 분류 판매 가능한 것만
|
||||
$hsql = " select ca_id, ca_name from {$g5['g5_shop_category_table']} where length(ca_id) = '2' and ca_use = '1' order by ca_order, ca_id ";
|
||||
$hresult = sql_query($hsql);
|
||||
$gnb_zindex = 999; // gnb_1dli z-index 값 설정용
|
||||
for ($i=0; $row=sql_fetch_array($hresult); $i++)
|
||||
{
|
||||
$i = 0;
|
||||
foreach($mshop_categories as $cate1) {
|
||||
if( empty($cate1) ) continue;
|
||||
|
||||
$row = $cate1['text'];
|
||||
$gnb_zindex -= 1; // html 구조에서 앞선 gnb_1dli 에 더 높은 z-index 값 부여
|
||||
// 2단계 분류 판매 가능한 것만
|
||||
$sql2 = " select ca_id, ca_name from {$g5['g5_shop_category_table']} where LENGTH(ca_id) = '4' and SUBSTRING(ca_id,1,2) = '{$row['ca_id']}' and ca_use = '1' order by ca_order, ca_id ";
|
||||
$result2 = sql_query($sql2);
|
||||
$count = sql_num_rows($result2);
|
||||
$count = ((int) count($cate1)) - 1;
|
||||
?>
|
||||
<li class="gnb_1dli" style="z-index:<?php echo $gnb_zindex; ?>">
|
||||
<a href="<?php echo G5_SHOP_URL.'/list.php?ca_id='.$row['ca_id']; ?>" class="gnb_1da<?php if ($count) echo ' gnb_1dam'; ?>"><?php echo $row['ca_name']; ?></a>
|
||||
<a href="<?php echo $row['url']; ?>" class="gnb_1da"><?php echo $row['ca_name']; ?><?php if ($count) echo '<i class="fa fa-angle-right" aria-hidden="true"></i>'; ?></a>
|
||||
<?php
|
||||
for ($j=0; $row2=sql_fetch_array($result2); $j++)
|
||||
{
|
||||
$j=0;
|
||||
foreach($cate1 as $key=>$cate2) {
|
||||
if( empty($cate2) || $key === 'text' ) continue;
|
||||
|
||||
$row2 = $cate2['text'];
|
||||
if ($j==0) echo '<ul class="gnb_2dul" style="z-index:'.$gnb_zindex.'">';
|
||||
?>
|
||||
<li class="gnb_2dli"><a href="<?php echo G5_SHOP_URL; ?>/list.php?ca_id=<?php echo $row2['ca_id']; ?>" class="gnb_2da"><?php echo $row2['ca_name']; ?></a></li>
|
||||
<?php }
|
||||
<li class="gnb_2dli"><a href="<?php echo $row2['url']; ?>" class="gnb_2da"><?php echo $row2['ca_name']; ?></a></li>
|
||||
<?php $j++; } //end for
|
||||
if ($j>0) echo '</ul>';
|
||||
?>
|
||||
</li>
|
||||
<?php } ?>
|
||||
<?php $i++; } //end for ?>
|
||||
</ul>
|
||||
</nav>
|
||||
<!-- } 쇼핑몰 카테고리 끝 -->
|
||||
@ -8,21 +8,18 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<!-- 쇼핑몰 커뮤니티 시작 { -->
|
||||
<aside id="scomm">
|
||||
<h2>커뮤니티</h2>
|
||||
|
||||
<ul>
|
||||
|
||||
<?php
|
||||
$hsql = " select bo_table, bo_subject from {$g5['board_table']} order by gr_id, bo_table ";
|
||||
$hresult = sql_query($hsql);
|
||||
for ($i=0; $row=sql_fetch_array($hresult); $i++)
|
||||
{
|
||||
echo '<li><i class="fa fa-angle-right" aria-hidden="true"></i> <a href="'.G5_BBS_URL.'/board.php?bo_table='.$row['bo_table'].'">'.$row['bo_subject'].'</a></li>'.PHP_EOL;
|
||||
echo '<li><i class="fa fa-angle-right" aria-hidden="true"></i> <a href="'.get_pretty_url($row['bo_table']).'">'.$row['bo_subject'].'</a></li>'.PHP_EOL;
|
||||
}
|
||||
|
||||
if ($i==0)
|
||||
echo '<li id="scomm_empty">커뮤니티 준비 중</li>'.PHP_EOL;
|
||||
?>
|
||||
</ul>
|
||||
|
||||
</aside>
|
||||
<!-- } 쇼핑몰 커뮤니티 끝 -->
|
||||
@ -8,10 +8,11 @@ $hresult = sql_query($hsql);
|
||||
if(sql_num_rows($hresult)) {
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
?>
|
||||
<div id="sev">
|
||||
<h2>이벤트</h2>
|
||||
<header>
|
||||
<h2>이벤트</h2>
|
||||
</header>
|
||||
<ul>
|
||||
<?php
|
||||
for ($i=0; $row=sql_fetch_array($hresult); $i++)
|
||||
@ -22,7 +23,7 @@ if(sql_num_rows($hresult)) {
|
||||
$event_img = G5_DATA_PATH.'/event/'.$row['ev_id'].'_m'; // 이벤트 이미지
|
||||
|
||||
if (file_exists($event_img)) { // 이벤트 이미지가 있다면 이미지 출력
|
||||
echo '<a href="'.$href.'" class="sev_img "><img src="'.G5_DATA_URL.'/event/'.$row['ev_id'].'_m" alt="'.$row['ev_subject'].'"></a>'.PHP_EOL;
|
||||
echo '<a href="'.$href.'" class="sev_img"><img src="'.G5_DATA_URL.'/event/'.$row['ev_id'].'_m" alt="'.$row['ev_subject'].'"></a>'.PHP_EOL;
|
||||
} else { // 없다면 텍스트 출력
|
||||
echo '<a href="'.$href.'" class="sev_text">';
|
||||
if ($row['ev_subject_strong']) echo '<strong>';
|
||||
@ -33,17 +34,17 @@ if(sql_num_rows($hresult)) {
|
||||
|
||||
// 이벤트 상품
|
||||
$sql2 = " select b.*
|
||||
from `{$g5['g5_shop_event_item_table']}` a left join `{$g5['g5_shop_item_table']}` b on (a.it_id = b.it_id)
|
||||
where a.ev_id = '{$row['ev_id']}'
|
||||
order by it_id desc
|
||||
limit 0, 2 ";
|
||||
from `{$g5['g5_shop_event_item_table']}` a left join `{$g5['g5_shop_item_table']}` b on (a.it_id = b.it_id)
|
||||
where a.ev_id = '{$row['ev_id']}'
|
||||
order by it_id desc
|
||||
limit 0, 3 ";
|
||||
$result2 = sql_query($sql2);
|
||||
for($k=1; $row2=sql_fetch_array($result2); $k++) {
|
||||
if($k == 1) {
|
||||
echo '<ul class="ev_prd">'.PHP_EOL;
|
||||
}
|
||||
|
||||
$item_href = G5_SHOP_URL.'/item.php?it_id='.$row2['it_id'];
|
||||
$item_href = shop_item_url($row2['it_id']);
|
||||
|
||||
echo '<li class="ev_prd_'.$k.'">'.PHP_EOL;
|
||||
echo '<span class="ev_prd_img">'.get_it_image($row2['it_id'], 110, 110, get_text($row2['it_name'])).'</span>'.PHP_EOL;
|
||||
@ -51,7 +52,7 @@ if(sql_num_rows($hresult)) {
|
||||
echo '<span class="ev_prd_price">'.display_price(get_price($row2), $row2['it_tel_inq']).'</span></div>'.PHP_EOL;
|
||||
echo '</li>'.PHP_EOL;
|
||||
}
|
||||
|
||||
echo '<li><a href="'.$href.'" class="sev_more">더보기</a></li>'.PHP_EOL;
|
||||
if($k > 1) {
|
||||
echo '</ul>'.PHP_EOL;
|
||||
}
|
||||
@ -61,7 +62,9 @@ if(sql_num_rows($hresult)) {
|
||||
echo '<li class="no_prd">등록된 상품이 없습니다.</li>'.PHP_EOL;
|
||||
echo '</ul>'.PHP_EOL;
|
||||
}
|
||||
echo '</div></li>'.PHP_EOL;
|
||||
//echo '<a href="'.$href.'" class="sev_more">더보기</a>'.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '</li>'.PHP_EOL;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -4,19 +4,17 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
$tv_datas = get_view_today_items(true);
|
||||
|
||||
$tv_div['top'] = 0;
|
||||
$tv_div['img_width'] = 60;
|
||||
$tv_div['img_height'] = 60;
|
||||
$tv_div['img_length'] = 3; // 한번에 보여줄 이미지 수
|
||||
$tv_div['img_width'] = 65;
|
||||
$tv_div['img_height'] = 65;
|
||||
$tv_div['img_length'] = 10; // 한번에 보여줄 이미지 수
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 오늘 본 상품 시작 { -->
|
||||
<div id="stv" class="op_area">
|
||||
<h2>
|
||||
오늘 본 상품
|
||||
</h2>
|
||||
<div id="stv">
|
||||
<h2 class="s_h2">오늘 본 상품 <span><?php echo get_view_today_items_count(); ?></span></h2>
|
||||
|
||||
<?php if ($tv_datas) { // 오늘 본 상품이 1개라도 있을 때 ?>
|
||||
<?php
|
||||
@ -42,12 +40,14 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
echo '<div class="prd_img">';
|
||||
echo $img;
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '<div class="prd_name">';
|
||||
echo '<div class="prd_cnt">';
|
||||
echo '<span class="prd_name">';
|
||||
echo cut_str($it_name, 10, '').PHP_EOL;
|
||||
echo '</div>';
|
||||
echo '<div class="prd_cost">';
|
||||
echo '</span>';
|
||||
echo '<span class="prd_cost">';
|
||||
echo $print_price.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '</span>'.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '</li>'.PHP_EOL;
|
||||
|
||||
$tv_tot_count++;
|
||||
@ -55,57 +55,56 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
}
|
||||
if ($tv_tot_count > 0) echo '</ul>'.PHP_EOL;
|
||||
?>
|
||||
<div id="stv_btn"></div>
|
||||
<span id="stv_pg"></span>
|
||||
<div id="stv_btn"></div>
|
||||
<span id="stv_pg"></span>
|
||||
|
||||
<script>
|
||||
$(function() {
|
||||
var itemQty = <?php echo $tv_tot_count; ?>; // 총 아이템 수량
|
||||
var itemShow = <?php echo $tv_div['img_length']; ?>; // 한번에 보여줄 아이템 수량
|
||||
if (itemQty > itemShow)
|
||||
<script>
|
||||
$(function() {
|
||||
var itemQty = <?php echo $tv_tot_count; ?>; // 총 아이템 수량
|
||||
var itemShow = <?php echo $tv_div['img_length']; ?>; // 한번에 보여줄 아이템 수량
|
||||
if (itemQty > itemShow)
|
||||
{
|
||||
$('#stv_btn').append('<button type="button" id="up"><i class="fa fa-angle-left" aria-hidden="true"></i> 이전</button><button type="button" id="down">다음 <i class="fa fa-angle-right" aria-hidden="true"></i></button>');
|
||||
}
|
||||
var Flag = 1; // 페이지
|
||||
var EOFlag = parseInt(<?php echo $i-1; ?>/itemShow); // 전체 리스트를 3(한 번에 보여줄 값)으로 나눠 페이지 최댓값을 구하고
|
||||
var itemRest = parseInt(<?php echo $i-1; ?>%itemShow); // 나머지 값을 구한 후
|
||||
if (itemRest > 0) // 나머지 값이 있다면
|
||||
{
|
||||
EOFlag++; // 페이지 최댓값을 1 증가시킨다.
|
||||
}
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 초기 출력값
|
||||
$('#up').click(function() {
|
||||
if (Flag == 1)
|
||||
{
|
||||
$('#stv_btn').append('<button type="button" id="up"><i class="fa fa-angle-left" aria-hidden="true"></i> 이전</button><button type="button" id="down">다음 <i class="fa fa-angle-right" aria-hidden="true"></i></button>');
|
||||
alert('목록의 처음입니다.');
|
||||
} else {
|
||||
Flag--;
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('.c'+(Flag+1)).css('display','none');
|
||||
}
|
||||
var Flag = 1; // 페이지
|
||||
var EOFlag = parseInt(<?php echo $i-1; ?>/itemShow); // 전체 리스트를 3(한 번에 보여줄 값)으로 나눠 페이지 최댓값을 구하고
|
||||
var itemRest = parseInt(<?php echo $i-1; ?>%itemShow); // 나머지 값을 구한 후
|
||||
if (itemRest > 0) // 나머지 값이 있다면
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 값 재설정
|
||||
})
|
||||
$('#down').click(function() {
|
||||
if (Flag == EOFlag)
|
||||
{
|
||||
EOFlag++; // 페이지 최댓값을 1 증가시킨다.
|
||||
alert('더 이상 목록이 없습니다.');
|
||||
} else {
|
||||
Flag++;
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('.c'+(Flag-1)).css('display','none');
|
||||
}
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 초기 출력값
|
||||
$('#up').click(function() {
|
||||
if (Flag == 1)
|
||||
{
|
||||
alert('목록의 처음입니다.');
|
||||
} else {
|
||||
Flag--;
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('.c'+(Flag+1)).css('display','none');
|
||||
}
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 값 재설정
|
||||
})
|
||||
$('#down').click(function() {
|
||||
if (Flag == EOFlag)
|
||||
{
|
||||
alert('더 이상 목록이 없습니다.');
|
||||
} else {
|
||||
Flag++;
|
||||
$('.c'+Flag).css('display','block');
|
||||
$('.c'+(Flag-1)).css('display','none');
|
||||
}
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 값 재설정
|
||||
});
|
||||
$('#stv_pg').text(Flag+'/'+EOFlag); // 페이지 값 재설정
|
||||
});
|
||||
</script>
|
||||
});
|
||||
</script>
|
||||
|
||||
<?php } else { // 오늘 본 상품이 없을 때 ?>
|
||||
<?php } else { // 오늘 본 상품이 없을 때 ?>
|
||||
|
||||
<p class="li_empty">없음</p>
|
||||
|
||||
<?php } ?>
|
||||
<p class="li_empty">없음</p>
|
||||
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<script src="<?php echo G5_JS_URL ?>/scroll_oldie.js"></script>
|
||||
|
||||
@ -6,9 +6,8 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
?>
|
||||
|
||||
<!-- 위시리스트 간략 보기 시작 { -->
|
||||
<aside id="swish" class="op_area">
|
||||
<h2>위시리스트</h2>
|
||||
|
||||
<aside id="wish" class="side-wish">
|
||||
<h2 class="s_h2">위시리스트 <span><?php echo get_wishlist_datas_count(); ?></span></h2>
|
||||
<ul>
|
||||
<?php
|
||||
$wishlist_datas = get_wishlist_datas($member['mb_id'], true);
|
||||
@ -16,22 +15,28 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
foreach( (array) $wishlist_datas as $row )
|
||||
{
|
||||
if( !$row['it_id'] ) continue;
|
||||
|
||||
$item = get_shop_item($row['it_id'], true);
|
||||
|
||||
if( !$item['it_id'] ) continue;
|
||||
|
||||
echo '<li>';
|
||||
$it_name = get_text($row['it_name']);
|
||||
$it_name = get_text($item['it_name']);
|
||||
|
||||
// 이미지로 할 경우
|
||||
$it_img = get_it_image($row['it_id'], 60, 60, true);
|
||||
$it_img = get_it_image($row['it_id'], 65, 65, true);
|
||||
echo '<div class="prd_img">'.$it_img.'</div>';
|
||||
echo '<a href="'.G5_SHOP_URL.'/item.php?it_id='.$row['it_id'].'">'.$it_name.'</a>';
|
||||
//echo '<a href="'.G5_SHOP_URL.'/wishlist.php">'.$it_name.'</a>';
|
||||
echo '<div class="prd_cnt">';
|
||||
echo '<a href="'.shop_item_url($row['it_id']).'" class="prd_name">'.$it_name.'</a>';
|
||||
echo '<div class="prd_price">'.display_price(get_price($item), $item['it_tel_inq']).'</div>';
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '</li>';
|
||||
$i++;
|
||||
} //end foreach
|
||||
|
||||
if ($i==0)
|
||||
echo '<li class="li_empty">위시리스트 없음</li>'.PHP_EOL;
|
||||
?>
|
||||
?>
|
||||
</ul>
|
||||
|
||||
</aside>
|
||||
<!-- } 위시리스트 간략 보기 끝 -->
|
||||
|
||||
@ -14,6 +14,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
$result = sql_query($sql);
|
||||
|
||||
$coupon = '';
|
||||
$coupon_info_class = '';
|
||||
|
||||
for($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
if(!$row['cz_file'])
|
||||
@ -24,23 +25,28 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
continue;
|
||||
|
||||
$subj = get_text($row['cz_subject']);
|
||||
|
||||
|
||||
switch($row['cp_method']) {
|
||||
case '0':
|
||||
$sql3 = " select it_id, it_name from {$g5['g5_shop_item_table']} where it_id = '{$row['cp_target']}' ";
|
||||
$row3 = sql_fetch($sql3);
|
||||
$cp_target = '<a href="./item.php?it_id='.$row3['it_id'].'">'.get_text($row3['it_name']).'</a>';
|
||||
$row3 = get_shop_item($row['cp_target'], true);
|
||||
$cp_target = '개별상품할인';
|
||||
$cp_link ='<a href="'.shop_item_url($row3['it_id']).'" target="_blank">'.get_text($row3['it_name']).'</a>';
|
||||
$coupon_info_class = 'cp_2';
|
||||
break;
|
||||
case '1':
|
||||
$sql3 = " select ca_id, ca_name from {$g5['g5_shop_category_table']} where ca_id = '{$row['cp_target']}' ";
|
||||
$row3 = sql_fetch($sql3);
|
||||
$cp_target = '<a href="./list.php?ca_id='.$row3['ca_id'].'">'.get_text($row3['ca_name']).'</a>';
|
||||
$cp_target = '카테고리할인';
|
||||
$cp_link = '<a href="'.shop_category_url($row3['ca_id']).'" target="_blank">'.get_text($row3['ca_name']).'</a>';
|
||||
$coupon_info_class = 'cp_1';
|
||||
break;
|
||||
case '2':
|
||||
$cp_target = '주문금액할인';
|
||||
$cp_link = $cp_target = '주문금액할인';
|
||||
$coupon_info_class = 'cp_3';
|
||||
break;
|
||||
case '3':
|
||||
$cp_target = '배송비할인';
|
||||
$cp_link = $cp_target = '배송비할인';
|
||||
$coupon_info_class = 'cp_4';
|
||||
break;
|
||||
}
|
||||
|
||||
@ -49,11 +55,37 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
if(is_coupon_downloaded($member['mb_id'], $row['cz_id']))
|
||||
$disabled = ' disabled';
|
||||
|
||||
// $row['cp_type'] 값이 있으면 % 이며 없으면 원 입니다.
|
||||
$print_cp_price = $row['cp_type'] ? '<b>'.$row['cp_price'].'</b> %' : '<b>'.number_format($row['cp_price']).'</b> 원';
|
||||
|
||||
$coupon .= '<li>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_img"><img src="'.str_replace(G5_PATH, G5_URL, $img_file).'" alt="'.$subj.'"></div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_tit">'.$subj.'</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_date">기한 : 다운로드 후 '.number_format($row['cz_period']).'일</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_target">적용 : '.$cp_target.'</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="cp_inner">'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_img"><img src="'.str_replace(G5_PATH, G5_URL, $img_file).'" alt="'.$subj.'">'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_tit"><strong>'.$subj.'</strong><br><span class="cp_evt">'.$print_cp_price.'</span></div>'.PHP_EOL;
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="cp_cnt">'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_target">'.PHP_EOL;
|
||||
$coupon .= '<span class="sound_only">적용</span><button class="coupon_info_btn '.$coupon_info_class.'">'.$cp_target.' <i class="fa fa-angle-right" aria-hidden="true"></i></button>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_info">
|
||||
<h4>'.$cp_target.'</h4>
|
||||
<ul>
|
||||
<li>적용 : '.$cp_link.'</li>';
|
||||
|
||||
if( $row['cp_minimum'] ){ // 쿠폰에 최소주문금액이 있다면
|
||||
$coupon .= '<li>최소주문금액 : <span class="cp_evt"><b>'.number_format($row['cp_minimum']).'</b>원</span></li>';
|
||||
}
|
||||
|
||||
$coupon .='</ul>
|
||||
<button class="coupon_info_cls"><i class="fa fa-times" aria-hidden="true"></i><span class="sound_only">닫기</span></button>
|
||||
</div>'.PHP_EOL;
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_date"><span class="sound_only">기한</span>다운로드 후 '.number_format($row['cz_period']).'일</div>'.PHP_EOL;
|
||||
//cp_1 카테고리할인
|
||||
//cp_2 개별상품할인
|
||||
//cp_3 주문금액할인
|
||||
//cp_4 배송비할인
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_btn"><button type="button" class="coupon_download btn02'.$disabled.'" data-cid="'.$row['cz_id'].'">쿠폰다운로드</button></div>'.PHP_EOL;
|
||||
$coupon .= '</li>'.PHP_EOL;
|
||||
}
|
||||
@ -74,6 +106,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
$result = sql_query($sql);
|
||||
|
||||
$coupon = '';
|
||||
$coupon_info_class = '';
|
||||
|
||||
for($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
if(!$row['cz_file'])
|
||||
@ -87,20 +120,25 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
|
||||
switch($row['cp_method']) {
|
||||
case '0':
|
||||
$sql3 = " select it_id, it_name from {$g5['g5_shop_item_table']} where it_id = '{$row['cp_target']}' ";
|
||||
$row3 = sql_fetch($sql3);
|
||||
$cp_target = '<a href="./item.php?it_id='.$row3['it_id'].'">'.get_text($row3['it_name']).'</a>';
|
||||
$row3 = get_shop_item($row['cp_target'], true);
|
||||
$cp_link = '<a href="'.shop_item_url($row3['it_id']).'" target="_blank">'.get_text($row3['it_name']).'</a>';
|
||||
$cp_target = '개별상품할인';
|
||||
$coupon_info_class = 'cp_2';
|
||||
break;
|
||||
case '1':
|
||||
$sql3 = " select ca_id, ca_name from {$g5['g5_shop_category_table']} where ca_id = '{$row['cp_target']}' ";
|
||||
$row3 = sql_fetch($sql3);
|
||||
$cp_target = '<a href="./list.php?ca_id='.$row3['ca_id'].'">'.get_text($row3['ca_name']).'</a>';
|
||||
$cp_link = '<a href="'.shop_category_url($row3['ca_id']).'" target="_blank">'.get_text($row3['ca_name']).'</a>';
|
||||
$cp_target = '카테고리할인';
|
||||
$coupon_info_class = 'cp_1';
|
||||
break;
|
||||
case '2':
|
||||
$cp_target = '주문금액할인';
|
||||
$cp_link = $cp_target = '주문금액할인';
|
||||
$coupon_info_class = 'cp_3';
|
||||
break;
|
||||
case '3':
|
||||
$cp_target = '배송비할인';
|
||||
$cp_link = $cp_target = '배송비할인';
|
||||
$coupon_info_class = 'cp_4';
|
||||
break;
|
||||
}
|
||||
|
||||
@ -109,13 +147,39 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
if(is_coupon_downloaded($member['mb_id'], $row['cz_id']))
|
||||
$disabled = ' disabled';
|
||||
|
||||
// $row['cp_type'] 값이 있으면 % 이며 없으면 원 입니다.
|
||||
$print_cp_price = $row['cp_type'] ? '<b>'.$row['cp_price'].'</b> %' : '<b>'.number_format($row['cp_price']).'</b> 원';
|
||||
|
||||
$coupon .= '<li>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_img"><img src="'.str_replace(G5_PATH, G5_URL, $img_file).'" alt="'.$subj.'"></div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_tit">'.$subj.'</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_date">기한 : 다운로드 후 '.number_format($row['cz_period']).'일</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_target">적용 : '.$cp_target.'</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_point">포인트 '.number_format($row['cz_point']).'점 차감</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_btn"><button type="button" class="coupon_download btn02'.$disabled.'" data-cid="'.$row['cz_id'].'">쿠폰다운로드</button></div>'.PHP_EOL;
|
||||
$coupon .= '<div class="cp_inner">'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_img"><img src="'.str_replace(G5_PATH, G5_URL, $img_file).'" alt="'.$subj.'">'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_tit"><strong>'.$subj.'</strong><br><span class="cp_evt">'.$print_cp_price.'</span></div>'.PHP_EOL;
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="cp_cnt">'.PHP_EOL;
|
||||
|
||||
$coupon .= '<div class="coupon_target">'.PHP_EOL;
|
||||
$coupon .= '<span class="sound_only">적용</span><button class="coupon_info_btn '.$coupon_info_class.'">'.$cp_target.' <i class="fa fa-angle-right" aria-hidden="true"></i></button>'.PHP_EOL;
|
||||
|
||||
$coupon .= '<div class="coupon_info">
|
||||
<h4>'.$cp_target.'</h4>
|
||||
<ul>
|
||||
<li>적용 : '.$cp_link.'</li>';
|
||||
|
||||
if( $row['cp_minimum'] ){ // 쿠폰에 최소주문금액이 있다면
|
||||
$coupon .= '<li>최소주문금액 : <span class="cp_evt"><b>'.number_format($row['cp_minimum']).'</b>원</span></li>';
|
||||
}
|
||||
|
||||
$coupon .= '</ul>
|
||||
<button class="coupon_info_cls"><i class="fa fa-times" aria-hidden="true"></i><span class="sound_only">닫기</span></button>
|
||||
</div>'.PHP_EOL;
|
||||
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
|
||||
$coupon .= '<div class="coupon_date"><span class="sound_only">기한</span>다운로드 후 '.number_format($row['cz_period']).'일</div>'.PHP_EOL;
|
||||
$coupon .= '<div class="coupon_btn"><button type="button" class="coupon_download btn02'.$disabled.'" data-cid="'.$row['cz_id'].'">포인트 '.number_format($row['cz_point']).'점 차감</button></div>'.PHP_EOL;
|
||||
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '</div>'.PHP_EOL;
|
||||
$coupon .= '</li>'.PHP_EOL;
|
||||
}
|
||||
|
||||
@ -124,4 +188,21 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
else
|
||||
echo '<p class="no_coupon">사용할 수 있는 쿠폰이 없습니다.</p>';
|
||||
?>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
<script>
|
||||
$(function (){
|
||||
$(".coupon_info_btn").on("click", function() {
|
||||
$(this).parent("div").children(".coupon_info").show();
|
||||
});
|
||||
$(".coupon_info_cls").on("click", function() {
|
||||
$(".coupon_info").hide();
|
||||
});
|
||||
// 쿠폰 정보창 닫기
|
||||
$(document).mouseup(function (e){
|
||||
var container = $(".coupon_info");
|
||||
if( container.has(e.target).length === 0)
|
||||
container.hide();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 322 B |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 328 B |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 322 B |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 328 B |
BIN
theme/basic/skin/shop/basic/img/chk.png
Normal file
|
After Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 23 KiB |
BIN
theme/basic/skin/shop/basic/img/select_arrow.png
Normal file
|
After Width: | Height: | Size: 160 B |
BIN
theme/basic/skin/shop/basic/img/select_arrow_left.png
Normal file
|
After Width: | Height: | Size: 2.8 KiB |
BIN
theme/basic/skin/shop/basic/img/select_arrow_next.png
Normal file
|
After Width: | Height: | Size: 995 B |
BIN
theme/basic/skin/shop/basic/img/select_arrow_prev.png
Normal file
|
After Width: | Height: | Size: 988 B |
BIN
theme/basic/skin/shop/basic/img/select_arrow_right.png
Normal file
|
After Width: | Height: | Size: 2.8 KiB |
BIN
theme/basic/skin/shop/basic/img/sit_siblings.jpg
Normal file
|
After Width: | Height: | Size: 558 B |
|
Before Width: | Height: | Size: 521 B |
|
Before Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 972 B |
|
Before Width: | Height: | Size: 549 B |
@ -4,367 +4,368 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
?>
|
||||
<div id="sit_ov_from">
|
||||
<form name="fitem" method="post" action="<?php echo $action_url; ?>" onsubmit="return fitem_submit(this);">
|
||||
<input type="hidden" name="it_id[]" value="<?php echo $it_id; ?>">
|
||||
<input type="hidden" name="sw_direct">
|
||||
<input type="hidden" name="url">
|
||||
|
||||
<div id="sit_ov_wrap">
|
||||
<!-- 상품이미지 미리보기 시작 { -->
|
||||
<div id="sit_pvi">
|
||||
<div id="sit_pvi_big">
|
||||
<?php
|
||||
$big_img_count = 0;
|
||||
$thumbnails = array();
|
||||
for($i=1; $i<=10; $i++) {
|
||||
if(!$it['it_img'.$i])
|
||||
continue;
|
||||
|
||||
$img = get_it_thumbnail($it['it_img'.$i], $default['de_mimg_width'], $default['de_mimg_height']);
|
||||
|
||||
if($img) {
|
||||
// 썸네일
|
||||
$thumb = get_it_thumbnail($it['it_img'.$i], 70, 70);
|
||||
$thumbnails[] = $thumb;
|
||||
$big_img_count++;
|
||||
|
||||
echo '<a href="'.G5_SHOP_URL.'/largeimage.php?it_id='.$it['it_id'].'&no='.$i.'" target="_blank" class="popup_item_image">'.$img.'</a>';
|
||||
}
|
||||
}
|
||||
|
||||
if($big_img_count == 0) {
|
||||
echo '<img src="'.G5_SHOP_URL.'/img/no_image.gif" alt="">';
|
||||
}
|
||||
?>
|
||||
<a href="<?php echo G5_SHOP_URL; ?>/largeimage.php?it_id=<?php echo $it['it_id']; ?>&no=1" target="_blank" id="popup_item_image" class="popup_item_image"><i class="fa fa-search-plus" aria-hidden="true"></i><span class="sound_only">확대보기</span></a>
|
||||
</div>
|
||||
<?php
|
||||
// 썸네일
|
||||
$thumb1 = true;
|
||||
$thumb_count = 0;
|
||||
$total_count = count($thumbnails);
|
||||
if($total_count > 0) {
|
||||
echo '<ul id="sit_pvi_thumb">';
|
||||
foreach($thumbnails as $val) {
|
||||
$thumb_count++;
|
||||
$sit_pvi_last ='';
|
||||
if ($thumb_count % 5 == 0) $sit_pvi_last = 'class="li_last"';
|
||||
echo '<li '.$sit_pvi_last.'>';
|
||||
echo '<a href="'.G5_SHOP_URL.'/largeimage.php?it_id='.$it['it_id'].'&no='.$thumb_count.'" target="_blank" class="popup_item_image img_thumb">'.$val.'<span class="sound_only"> '.$thumb_count.'번째 이미지 새창</span></a>';
|
||||
echo '</li>';
|
||||
}
|
||||
echo '</ul>';
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<!-- } 상품이미지 미리보기 끝 -->
|
||||
|
||||
<!-- 상품 요약정보 및 구매 시작 { -->
|
||||
<section id="sit_ov" class="2017_renewal_itemform">
|
||||
<h2 id="sit_title"><?php echo stripslashes($it['it_name']); ?> <span class="sound_only">요약정보 및 구매</span></h2>
|
||||
<p id="sit_desc"><?php echo $it['it_basic']; ?></p>
|
||||
<?php if($is_orderable) { ?>
|
||||
<p id="sit_opt_info">
|
||||
상품 선택옵션 <?php echo $option_count; ?> 개, 추가옵션 <?php echo $supply_count; ?> 개
|
||||
</p>
|
||||
<?php } ?>
|
||||
|
||||
<div id="sit_star_sns">
|
||||
<?php if ($star_score) { ?>
|
||||
<span class="sound_only">고객평점</span>
|
||||
<img src="<?php echo G5_SHOP_URL; ?>/img/s_star<?php echo $star_score?>.png" alt="" class="sit_star" width="100">
|
||||
<span class="sound_only">별<?php echo $star_score?>개</span>
|
||||
<?php } ?>
|
||||
|
||||
<span class="">사용후기 <?php echo $it['it_use_cnt']; ?> 개</span>
|
||||
|
||||
<div id="sit_btn_opt">
|
||||
<span id="btn_wish"><i class="fa fa-heart-o" aria-hidden="true"></i><span class="sound_only">위시리스트</span><span class="btn_wish_num"><?php echo get_wishlist_count_by_item($it['it_id']); ?></span></span>
|
||||
<button type="button" class="btn_sns_share"><i class="fa fa-share-alt" aria-hidden="true"></i><span class="sound_only">sns 공유</span></button>
|
||||
<div class="sns_area">
|
||||
<?php echo $sns_share_links; ?>
|
||||
<a href="javascript:popup_item_recommend('<?php echo $it['it_id']; ?>');" id="sit_btn_rec"><i class="fa fa-envelope-o" aria-hidden="true"></i><span class="sound_only">추천하기</span></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$(".btn_sns_share").click(function(){
|
||||
$(".sns_area").show();
|
||||
});
|
||||
$(document).mouseup(function (e){
|
||||
var container = $(".sns_area");
|
||||
if( container.has(e.target).length === 0)
|
||||
container.hide();
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="sit_info">
|
||||
<table class="sit_ov_tbl">
|
||||
<colgroup>
|
||||
<col class="grid_3">
|
||||
<col>
|
||||
</colgroup>
|
||||
<tbody>
|
||||
|
||||
<?php if (!$it['it_use']) { // 판매가능이 아닐 경우 ?>
|
||||
<tr>
|
||||
<th scope="row">판매가격</th>
|
||||
<td>판매중지</td>
|
||||
</tr>
|
||||
<?php } else if ($it['it_tel_inq']) { // 전화문의일 경우 ?>
|
||||
<tr>
|
||||
<th scope="row">판매가격</th>
|
||||
<td>전화문의</td>
|
||||
</tr>
|
||||
<?php } else { // 전화문의가 아닐 경우?>
|
||||
<?php if ($it['it_cust_price']) { ?>
|
||||
<tr>
|
||||
<th scope="row">시중가격</th>
|
||||
<td><?php echo display_price($it['it_cust_price']); ?></td>
|
||||
</tr>
|
||||
<?php } // 시중가격 끝 ?>
|
||||
|
||||
<tr class="tr_price">
|
||||
<th scope="row">판매가격</th>
|
||||
<td>
|
||||
<strong><?php echo display_price(get_price($it)); ?></strong>
|
||||
<input type="hidden" id="it_price" value="<?php echo get_price($it); ?>">
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_maker']) { ?>
|
||||
<tr>
|
||||
<th scope="row">제조사</th>
|
||||
<td><?php echo $it['it_maker']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_origin']) { ?>
|
||||
<tr>
|
||||
<th scope="row">원산지</th>
|
||||
<td><?php echo $it['it_origin']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_brand']) { ?>
|
||||
<tr>
|
||||
<th scope="row">브랜드</th>
|
||||
<td><?php echo $it['it_brand']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_model']) { ?>
|
||||
<tr>
|
||||
<th scope="row">모델</th>
|
||||
<td><?php echo $it['it_model']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<form name="fitem" method="post" action="<?php echo $action_url; ?>" onsubmit="return fitem_submit(this);">
|
||||
<input type="hidden" name="it_id[]" value="<?php echo $it_id; ?>">
|
||||
<input type="hidden" name="sw_direct">
|
||||
<input type="hidden" name="url">
|
||||
|
||||
<div id="sit_ov_wrap">
|
||||
<!-- 상품이미지 미리보기 시작 { -->
|
||||
<div id="sit_pvi">
|
||||
<div id="sit_pvi_big">
|
||||
<?php
|
||||
$big_img_count = 0;
|
||||
$thumbnails = array();
|
||||
for($i=1; $i<=10; $i++) {
|
||||
if(!$it['it_img'.$i])
|
||||
continue;
|
||||
|
||||
$img = get_it_thumbnail($it['it_img'.$i], $default['de_mimg_width'], $default['de_mimg_height']);
|
||||
|
||||
if($img) {
|
||||
// 썸네일
|
||||
$thumb = get_it_thumbnail($it['it_img'.$i], 60, 60);
|
||||
$thumbnails[] = $thumb;
|
||||
$big_img_count++;
|
||||
|
||||
echo '<a href="'.G5_SHOP_URL.'/largeimage.php?it_id='.$it['it_id'].'&no='.$i.'" target="_blank" class="popup_item_image">'.$img.'</a>';
|
||||
}
|
||||
}
|
||||
|
||||
if($big_img_count == 0) {
|
||||
echo '<img src="'.G5_SHOP_URL.'/img/no_image.gif" alt="">';
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
// 썸네일
|
||||
$thumb1 = true;
|
||||
$thumb_count = 0;
|
||||
$total_count = count($thumbnails);
|
||||
if($total_count > 0) {
|
||||
echo '<ul id="sit_pvi_thumb">';
|
||||
foreach($thumbnails as $val) {
|
||||
$thumb_count++;
|
||||
$sit_pvi_last ='';
|
||||
if ($thumb_count % 5 == 0) $sit_pvi_last = 'class="li_last"';
|
||||
echo '<li '.$sit_pvi_last.'>';
|
||||
echo '<a href="'.G5_SHOP_URL.'/largeimage.php?it_id='.$it['it_id'].'&no='.$thumb_count.'" target="_blank" class="popup_item_image img_thumb">'.$val.'<span class="sound_only"> '.$thumb_count.'번째 이미지 새창</span></a>';
|
||||
echo '</li>';
|
||||
}
|
||||
echo '</ul>';
|
||||
}
|
||||
?>
|
||||
|
||||
<!-- 다른 상품 보기 시작 { -->
|
||||
<div id="sit_siblings">
|
||||
<?php
|
||||
if ($prev_href || $next_href) {
|
||||
$prev_title = '<i class="fa fa-caret-left" aria-hidden="true"></i> '.$prev_title;
|
||||
$next_title = $next_title.' <i class="fa fa-caret-right" aria-hidden="true"></i>';
|
||||
|
||||
echo $prev_href.$prev_title.$prev_href2;
|
||||
echo $next_href.$next_title.$next_href2;
|
||||
} else {
|
||||
echo '<span class="sound_only">이 분류에 등록된 다른 상품이 없습니다.</span>';
|
||||
}
|
||||
?>
|
||||
<a href="<?php echo G5_SHOP_URL; ?>/largeimage.php?it_id=<?php echo $it['it_id']; ?>&no=1" target="_blank" class="popup_item_image "><i class="fa fa-search-plus" aria-hidden="true"></i><span class="sound_only">확대보기</span></a>
|
||||
</div>
|
||||
<!-- } 다른 상품 보기 끝 -->
|
||||
|
||||
<div id="sit_star_sns">
|
||||
<?php if ($star_score) { ?>
|
||||
<span class="sound_only">고객평점</span>
|
||||
<img src="<?php echo G5_SHOP_URL; ?>/img/s_star<?php echo $star_score?>.png" alt="" class="sit_star" width="100">
|
||||
별<?php echo $star_score?>개
|
||||
<?php } ?>
|
||||
<span class="st_bg"></span> <i class="fa fa-commenting-o" aria-hidden="true"></i><span class="sound_only">리뷰</span> <?php echo $it['it_use_cnt']; ?>
|
||||
<span class="st_bg"></span> <i class="fa fa-heart-o" aria-hidden="true"></i><span class="sound_only">위시</span> <?php echo get_wishlist_count_by_item($it['it_id']); ?>
|
||||
<button type="button" class="btn_sns_share"><i class="fa fa-share-alt" aria-hidden="true"></i><span class="sound_only">sns 공유</span></button>
|
||||
<div class="sns_area"><?php echo $sns_share_links; ?> <a href="javascript:popup_item_recommend('<?php echo $it['it_id']; ?>');" id="sit_btn_rec"><i class="fa fa-envelope-o" aria-hidden="true"></i><span class="sound_only">추천하기</span></a></div>
|
||||
</div>
|
||||
<script>
|
||||
$(".btn_sns_share").click(function(){
|
||||
$(".sns_area").show();
|
||||
});
|
||||
$(document).mouseup(function (e){
|
||||
var container = $(".sns_area");
|
||||
if( container.has(e.target).length === 0)
|
||||
container.hide();
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
</div>
|
||||
<!-- } 상품이미지 미리보기 끝 -->
|
||||
|
||||
<!-- 상품 요약정보 및 구매 시작 { -->
|
||||
<section id="sit_ov" class="2017_renewal_itemform">
|
||||
<h2 id="sit_title"><?php echo stripslashes($it['it_name']); ?> <span class="sound_only">요약정보 및 구매</span></h2>
|
||||
<p id="sit_desc"><?php echo $it['it_basic']; ?></p>
|
||||
<?php if($is_orderable) { ?>
|
||||
<p id="sit_opt_info">
|
||||
상품 선택옵션 <?php echo $option_count; ?> 개, 추가옵션 <?php echo $supply_count; ?> 개
|
||||
</p>
|
||||
<?php } ?>
|
||||
<div class="sit_info">
|
||||
<table class="sit_ov_tbl">
|
||||
<colgroup>
|
||||
<col class="grid_3">
|
||||
<col>
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<?php if ($it['it_maker']) { ?>
|
||||
<tr>
|
||||
<th scope="row">제조사</th>
|
||||
<td><?php echo $it['it_maker']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_origin']) { ?>
|
||||
<tr>
|
||||
<th scope="row">원산지</th>
|
||||
<td><?php echo $it['it_origin']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_brand']) { ?>
|
||||
<tr>
|
||||
<th scope="row">브랜드</th>
|
||||
<td><?php echo $it['it_brand']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_model']) { ?>
|
||||
<tr>
|
||||
<th scope="row">모델</th>
|
||||
<td><?php echo $it['it_model']; ?></td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php if (!$it['it_use']) { // 판매가능이 아닐 경우 ?>
|
||||
<tr>
|
||||
<th scope="row">판매가격</th>
|
||||
<td>판매중지</td>
|
||||
</tr>
|
||||
<?php } else if ($it['it_tel_inq']) { // 전화문의일 경우 ?>
|
||||
<tr>
|
||||
<th scope="row">판매가격</th>
|
||||
<td>전화문의</td>
|
||||
</tr>
|
||||
<?php } else { // 전화문의가 아닐 경우?>
|
||||
<?php if ($it['it_cust_price']) { ?>
|
||||
<tr>
|
||||
<th scope="row">시중가격</th>
|
||||
<td><?php echo display_price($it['it_cust_price']); ?></td>
|
||||
</tr>
|
||||
<?php } // 시중가격 끝 ?>
|
||||
|
||||
<tr>
|
||||
<th scope="row">판매가격</th>
|
||||
<td>
|
||||
<strong><?php echo display_price(get_price($it)); ?></strong>
|
||||
<input type="hidden" id="it_price" value="<?php echo get_price($it); ?>">
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
|
||||
<?php
|
||||
/* 재고 표시하는 경우 주석 해제
|
||||
<tr>
|
||||
<th scope="row">재고수량</th>
|
||||
<td><?php echo number_format(get_it_stock_qty($it_id)); ?> 개</td>
|
||||
</tr>
|
||||
*/
|
||||
?>
|
||||
|
||||
<?php if ($config['cf_use_point']) { // 포인트 사용한다면 ?>
|
||||
<tr>
|
||||
<th scope="row">포인트</th>
|
||||
<td>
|
||||
<?php
|
||||
if($it['it_point_type'] == 2) {
|
||||
echo '구매금액(추가옵션 제외)의 '.$it['it_point'].'%';
|
||||
} else {
|
||||
$it_point = get_item_point($it);
|
||||
echo number_format($it_point).'점';
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<?php
|
||||
$ct_send_cost_label = '배송비결제';
|
||||
|
||||
if($it['it_sc_type'] == 1)
|
||||
$sc_method = '무료배송';
|
||||
else {
|
||||
if($it['it_sc_method'] == 1)
|
||||
$sc_method = '수령후 지불';
|
||||
else if($it['it_sc_method'] == 2) {
|
||||
$ct_send_cost_label = '<label for="ct_send_cost">배송비결제</label>';
|
||||
$sc_method = '<select name="ct_send_cost" id="ct_send_cost">
|
||||
<option value="0">주문시 결제</option>
|
||||
<option value="1">수령후 지불</option>
|
||||
</select>';
|
||||
}
|
||||
else
|
||||
$sc_method = '주문시 결제';
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<th><?php echo $ct_send_cost_label; ?></th>
|
||||
<td><?php echo $sc_method; ?></td>
|
||||
</tr>
|
||||
<?php if($it['it_buy_min_qty']) { ?>
|
||||
<tr>
|
||||
<th>최소구매수량</th>
|
||||
<td><?php echo number_format($it['it_buy_min_qty']); ?> 개</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<?php if($it['it_buy_max_qty']) { ?>
|
||||
<tr>
|
||||
<th>최대구매수량</th>
|
||||
<td><?php echo number_format($it['it_buy_max_qty']); ?> 개</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
if($option_item) {
|
||||
?>
|
||||
<!-- 선택옵션 시작 { -->
|
||||
<section class="sit_option">
|
||||
<h3>선택옵션</h3>
|
||||
|
||||
<?php // 선택옵션
|
||||
echo $option_item;
|
||||
?>
|
||||
</section>
|
||||
<!-- } 선택옵션 끝 -->
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
<?php
|
||||
if($supply_item) {
|
||||
?>
|
||||
<!-- 추가옵션 시작 { -->
|
||||
<section class="sit_option">
|
||||
<h3>추가옵션</h3>
|
||||
<?php // 추가옵션
|
||||
echo $supply_item;
|
||||
?>
|
||||
</section>
|
||||
<!-- } 추가옵션 끝 -->
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ($is_orderable) { ?>
|
||||
<!-- 선택된 옵션 시작 { -->
|
||||
<section id="sit_sel_option">
|
||||
<h3>선택된 옵션</h3>
|
||||
<?php
|
||||
if(!$option_item) {
|
||||
if(!$it['it_buy_min_qty'])
|
||||
$it['it_buy_min_qty'] = 1;
|
||||
?>
|
||||
<ul id="sit_opt_added">
|
||||
<li class="sit_opt_list">
|
||||
|
||||
<input type="hidden" name="io_type[<?php echo $it_id; ?>][]" value="0">
|
||||
<input type="hidden" name="io_id[<?php echo $it_id; ?>][]" value="">
|
||||
<input type="hidden" name="io_value[<?php echo $it_id; ?>][]" value="<?php echo $it['it_name']; ?>">
|
||||
<input type="hidden" class="io_price" value="0">
|
||||
<input type="hidden" class="io_stock" value="<?php echo $it['it_stock_qty']; ?>">
|
||||
<div class="opt_name">
|
||||
<span class="sit_opt_subj"><?php echo $it['it_name']; ?></span>
|
||||
</div>
|
||||
<div class="opt_count">
|
||||
<label for="ct_qty_<?php echo $i; ?>" class="sound_only">수량</label>
|
||||
<button type="button" class="sit_qty_minus"><i class="fa fa-minus" aria-hidden="true"></i><span class="sound_only">감소</span></button>
|
||||
<input type="text" name="ct_qty[<?php echo $it_id; ?>][]" value="<?php echo $it['it_buy_min_qty']; ?>" id="ct_qty_<?php echo $i; ?>" class="num_input" size="5">
|
||||
<button type="button" class="sit_qty_plus"><i class="fa fa-plus" aria-hidden="true"></i><span class="sound_only">증가</span></button>
|
||||
<span class="sit_opt_prc">+0원</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<script>
|
||||
$(function() {
|
||||
price_calculate();
|
||||
});
|
||||
</script>
|
||||
<?php } ?>
|
||||
</section>
|
||||
<!-- } 선택된 옵션 끝 -->
|
||||
|
||||
<!-- 총 구매액 -->
|
||||
<div id="sit_tot_price"></div>
|
||||
<?php } ?>
|
||||
|
||||
<?php if($is_soldout) { ?>
|
||||
<p id="sit_ov_soldout">상품의 재고가 부족하여 구매할 수 없습니다.</p>
|
||||
<?php } ?>
|
||||
|
||||
<div id="sit_ov_btn">
|
||||
<?php if ($is_orderable) { ?>
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="바로구매" id="sit_btn_buy"><i class="fa fa-credit-card" aria-hidden="true"></i> 바로구매</button>
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="장바구니" id="sit_btn_cart"><i class="fa fa-shopping-cart" aria-hidden="true"></i> 장바구니</button>
|
||||
<?php } ?>
|
||||
<?php if(!$is_orderable && $it['it_soldout'] && $it['it_stock_sms']) { ?>
|
||||
<a href="javascript:popup_stocksms('<?php echo $it['it_id']; ?>');" id="sit_btn_alm"><i class="fa fa-bell-o" aria-hidden="true"></i> 재입고알림</a>
|
||||
<?php } ?>
|
||||
<a href="javascript:item_wish(document.fitem, '<?php echo $it['it_id']; ?>');" id="sit_btn_wish"><i class="fa fa-heart-o" aria-hidden="true"></i><span class="sound_only">위시리스트</span></a>
|
||||
<?php if ($naverpay_button_js) { ?>
|
||||
<div class="itemform-naverpay"><?php echo $naverpay_request_js.$naverpay_button_js; ?></div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// 상품보관
|
||||
function item_wish(f, it_id)
|
||||
{
|
||||
f.url.value = "<?php echo G5_SHOP_URL; ?>/wishupdate.php?it_id="+it_id;
|
||||
f.action = "<?php echo G5_SHOP_URL; ?>/wishupdate.php";
|
||||
f.submit();
|
||||
}
|
||||
|
||||
// 추천메일
|
||||
function popup_item_recommend(it_id)
|
||||
{
|
||||
if (!g5_is_member)
|
||||
{
|
||||
if (confirm("회원만 추천하실 수 있습니다."))
|
||||
document.location.href = "<?php echo G5_BBS_URL; ?>/login.php?url=<?php echo urlencode(G5_SHOP_URL."/item.php?it_id=$it_id"); ?>";
|
||||
}
|
||||
else
|
||||
{
|
||||
url = "./itemrecommend.php?it_id=" + it_id;
|
||||
opt = "scrollbars=yes,width=616,height=420,top=10,left=10";
|
||||
popup_window(url, "itemrecommend", opt);
|
||||
}
|
||||
}
|
||||
|
||||
// 재입고SMS 알림
|
||||
function popup_stocksms(it_id)
|
||||
{
|
||||
url = "<?php echo G5_SHOP_URL; ?>/itemstocksms.php?it_id=" + it_id;
|
||||
opt = "scrollbars=yes,width=616,height=420,top=10,left=10";
|
||||
popup_window(url, "itemstocksms", opt);
|
||||
}
|
||||
</script>
|
||||
</section>
|
||||
<!-- } 상품 요약정보 및 구매 끝 -->
|
||||
|
||||
<?php
|
||||
/* 재고 표시하는 경우 주석 해제
|
||||
<tr>
|
||||
<th scope="row">재고수량</th>
|
||||
<td><?php echo number_format(get_it_stock_qty($it_id)); ?> 개</td>
|
||||
</tr>
|
||||
*/
|
||||
?>
|
||||
|
||||
<?php if ($config['cf_use_point']) { // 포인트 사용한다면 ?>
|
||||
<tr>
|
||||
<th scope="row">포인트</th>
|
||||
<td>
|
||||
<?php
|
||||
if($it['it_point_type'] == 2) {
|
||||
echo '구매금액(추가옵션 제외)의 '.$it['it_point'].'%';
|
||||
} else {
|
||||
$it_point = get_item_point($it);
|
||||
echo number_format($it_point).'점';
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<?php
|
||||
$ct_send_cost_label = '배송비결제';
|
||||
|
||||
if($it['it_sc_type'] == 1)
|
||||
$sc_method = '무료배송';
|
||||
else {
|
||||
if($it['it_sc_method'] == 1)
|
||||
$sc_method = '수령후 지불';
|
||||
else if($it['it_sc_method'] == 2) {
|
||||
$ct_send_cost_label = '<label for="ct_send_cost">배송비결제</label>';
|
||||
$sc_method = '<select name="ct_send_cost" id="ct_send_cost">
|
||||
<option value="0">주문시 결제</option>
|
||||
<option value="1">수령후 지불</option>
|
||||
</select>';
|
||||
}
|
||||
else
|
||||
$sc_method = '주문시 결제';
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<th><?php echo $ct_send_cost_label; ?></th>
|
||||
<td><?php echo $sc_method; ?></td>
|
||||
</tr>
|
||||
<?php if($it['it_buy_min_qty']) { ?>
|
||||
<tr>
|
||||
<th>최소구매수량</th>
|
||||
<td><?php echo number_format($it['it_buy_min_qty']); ?> 개</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<?php if($it['it_buy_max_qty']) { ?>
|
||||
<tr>
|
||||
<th>최대구매수량</th>
|
||||
<td><?php echo number_format($it['it_buy_max_qty']); ?> 개</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
if($option_item) {
|
||||
?>
|
||||
<!-- 선택옵션 시작 { -->
|
||||
<section class="sit_option">
|
||||
<h3>선택옵션</h3>
|
||||
|
||||
<?php // 선택옵션
|
||||
echo $option_item;
|
||||
?>
|
||||
</section>
|
||||
<!-- } 선택옵션 끝 -->
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
<?php
|
||||
if($supply_item) {
|
||||
?>
|
||||
<!-- 추가옵션 시작 { -->
|
||||
<section class="sit_option">
|
||||
<h3>추가옵션</h3>
|
||||
<?php // 추가옵션
|
||||
echo $supply_item;
|
||||
?>
|
||||
</section>
|
||||
<!-- } 추가옵션 끝 -->
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
<?php if ($is_orderable) { ?>
|
||||
<!-- 선택된 옵션 시작 { -->
|
||||
<section id="sit_sel_option">
|
||||
<h3>선택된 옵션</h3>
|
||||
<?php
|
||||
if(!$option_item) {
|
||||
if(!$it['it_buy_min_qty'])
|
||||
$it['it_buy_min_qty'] = 1;
|
||||
?>
|
||||
<ul id="sit_opt_added">
|
||||
<li class="sit_opt_list">
|
||||
<input type="hidden" name="io_type[<?php echo $it_id; ?>][]" value="0">
|
||||
<input type="hidden" name="io_id[<?php echo $it_id; ?>][]" value="">
|
||||
<input type="hidden" name="io_value[<?php echo $it_id; ?>][]" value="<?php echo $it['it_name']; ?>">
|
||||
<input type="hidden" class="io_price" value="0">
|
||||
<input type="hidden" class="io_stock" value="<?php echo $it['it_stock_qty']; ?>">
|
||||
<div class="opt_name">
|
||||
<span class="sit_opt_subj"><?php echo $it['it_name']; ?></span>
|
||||
</div>
|
||||
<div class="opt_count">
|
||||
<label for="ct_qty_<?php echo $i; ?>" class="sound_only">수량</label>
|
||||
<button type="button" class="sit_qty_minus"><i class="fa fa-minus" aria-hidden="true"></i><span class="sound_only">감소</span></button>
|
||||
<input type="text" name="ct_qty[<?php echo $it_id; ?>][]" value="<?php echo $it['it_buy_min_qty']; ?>" id="ct_qty_<?php echo $i; ?>" class="num_input" size="5">
|
||||
<button type="button" class="sit_qty_plus"><i class="fa fa-plus" aria-hidden="true"></i><span class="sound_only">증가</span></button>
|
||||
<span class="sit_opt_prc">+0원</span>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
<script>
|
||||
$(function() {
|
||||
price_calculate();
|
||||
});
|
||||
</script>
|
||||
<?php } ?>
|
||||
</section>
|
||||
<!-- } 선택된 옵션 끝 -->
|
||||
|
||||
<!-- 총 구매액 -->
|
||||
<div id="sit_tot_price"></div>
|
||||
<?php } ?>
|
||||
|
||||
<?php if($is_soldout) { ?>
|
||||
<p id="sit_ov_soldout">상품의 재고가 부족하여 구매할 수 없습니다.</p>
|
||||
<?php } ?>
|
||||
|
||||
<div id="sit_ov_btn">
|
||||
<?php if ($is_orderable) { ?>
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="장바구니" class="sit_btn_cart">장바구니</button>
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="바로구매" class="sit_btn_buy">바로구매</button>
|
||||
<?php } ?>
|
||||
<a href="javascript:item_wish(document.fitem, '<?php echo $it['it_id']; ?>');" class="sit_btn_wish"><i class="fa fa-heart-o" aria-hidden="true"></i><span class="sound_only">위시리스트</span></a>
|
||||
|
||||
<?php if(!$is_orderable && $it['it_soldout'] && $it['it_stock_sms']) { ?>
|
||||
<a href="javascript:popup_stocksms('<?php echo $it['it_id']; ?>');" id="sit_btn_alm">재입고알림</a>
|
||||
<?php } ?>
|
||||
<?php if ($naverpay_button_js) { ?>
|
||||
<div class="itemform-naverpay"><?php echo $naverpay_request_js.$naverpay_button_js; ?></div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// 상품보관
|
||||
function item_wish(f, it_id)
|
||||
{
|
||||
f.url.value = "<?php echo G5_SHOP_URL; ?>/wishupdate.php?it_id="+it_id;
|
||||
f.action = "<?php echo G5_SHOP_URL; ?>/wishupdate.php";
|
||||
f.submit();
|
||||
}
|
||||
|
||||
// 추천메일
|
||||
function popup_item_recommend(it_id)
|
||||
{
|
||||
if (!g5_is_member)
|
||||
{
|
||||
if (confirm("회원만 추천하실 수 있습니다."))
|
||||
document.location.href = "<?php echo G5_BBS_URL; ?>/login.php?url=<?php echo urlencode(shop_item_url($it_id)); ?>";
|
||||
}
|
||||
else
|
||||
{
|
||||
url = "./itemrecommend.php?it_id=" + it_id;
|
||||
opt = "scrollbars=yes,width=616,height=420,top=10,left=10";
|
||||
popup_window(url, "itemrecommend", opt);
|
||||
}
|
||||
}
|
||||
|
||||
// 재입고SMS 알림
|
||||
function popup_stocksms(it_id)
|
||||
{
|
||||
url = "<?php echo G5_SHOP_URL; ?>/itemstocksms.php?it_id=" + it_id;
|
||||
opt = "scrollbars=yes,width=616,height=420,top=10,left=10";
|
||||
popup_window(url, "itemstocksms", opt);
|
||||
}
|
||||
</script>
|
||||
</section>
|
||||
<!-- } 상품 요약정보 및 구매 끝 -->
|
||||
</div>
|
||||
<!-- 다른 상품 보기 시작 { -->
|
||||
<div id="sit_siblings">
|
||||
<?php
|
||||
if ($prev_href || $next_href) {
|
||||
echo $prev_href.$prev_title.$prev_href2;
|
||||
echo $next_href.$next_title.$next_href2;
|
||||
} else {
|
||||
echo '<span class="sound_only">이 분류에 등록된 다른 상품이 없습니다.</span>';
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<!-- } 다른 상품 보기 끝 -->
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
// 상품이미지 첫번째 링크
|
||||
|
||||
@ -25,109 +25,308 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
<!-- } 관련상품 끝 -->
|
||||
<?php } ?>
|
||||
|
||||
<!-- 상품 정보 시작 { -->
|
||||
<section id="sit_inf">
|
||||
<h2>상품 정보</h2>
|
||||
<?php echo pg_anchor('inf'); ?>
|
||||
<section id="sit_info">
|
||||
<div id="sit_tab">
|
||||
<ul class="tab_tit">
|
||||
<li><button type="button" rel="#sit_inf" class="selected">상품정보</button></li>
|
||||
<li><button type="button" rel="#sit_use">사용후기 <span class="item_use_count"><?php echo $item_use_count; ?></span></button></li>
|
||||
<li><button type="button" rel="#sit_qa">상품문의 <span class="item_qa_count"><?php echo $item_qa_count; ?></span></button></li>
|
||||
<li><button type="button" rel="#sit_dex">배송/교환</button></li>
|
||||
</ul>
|
||||
<ul class="tab_con">
|
||||
|
||||
<!-- 상품 정보 시작 { -->
|
||||
<li id="sit_inf">
|
||||
<h2 class="contents_tit"><span>상품 정보</span></h2>
|
||||
|
||||
<?php if ($it['it_explan']) { // 상품 상세설명 ?>
|
||||
<h3>상품 상세설명</h3>
|
||||
<div id="sit_inf_explan">
|
||||
<?php echo ($it['it_mobile_explan'] ? conv_content($it['it_mobile_explan'], 1) : conv_content($it['it_explan'], 1)); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<?php
|
||||
if ($it['it_info_value']) { // 상품 정보 고시
|
||||
$info_data = unserialize(stripslashes($it['it_info_value']));
|
||||
if(is_array($info_data)) {
|
||||
$gubun = $it['it_info_gubun'];
|
||||
$info_array = $item_info[$gubun]['article'];
|
||||
?>
|
||||
<h3>상품 정보 고시</h3>
|
||||
<table id="sit_inf_open">
|
||||
<tbody>
|
||||
<?php
|
||||
foreach($info_data as $key=>$val) {
|
||||
$ii_title = $info_array[$key][0];
|
||||
$ii_value = $val;
|
||||
?>
|
||||
<tr>
|
||||
<th scope="row"><?php echo $ii_title; ?></th>
|
||||
<td><?php echo $ii_value; ?></td>
|
||||
</tr>
|
||||
<?php } //foreach?>
|
||||
</tbody>
|
||||
</table>
|
||||
<!-- 상품정보고시 end -->
|
||||
<?php
|
||||
} else {
|
||||
if($is_admin) {
|
||||
echo '<p>상품 정보 고시 정보가 올바르게 저장되지 않았습니다.<br>config.php 파일의 G5_ESCAPE_FUNCTION 설정을 addslashes 로<br>변경하신 후 관리자 > 상품정보 수정에서 상품 정보를 다시 저장해주세요. </p>';
|
||||
}
|
||||
}
|
||||
} //if
|
||||
?>
|
||||
|
||||
</li>
|
||||
<!-- 사용후기 시작 { -->
|
||||
<li id="sit_use">
|
||||
<h2>사용후기</h2>
|
||||
<div id="itemuse"><?php include_once(G5_SHOP_PATH.'/itemuse.php'); ?></div>
|
||||
</li>
|
||||
<!-- } 사용후기 끝 -->
|
||||
|
||||
<!-- 상품문의 시작 { -->
|
||||
<li id="sit_qa">
|
||||
<h2>상품문의</h2>
|
||||
<div id="itemqa"><?php include_once(G5_SHOP_PATH.'/itemqa.php'); ?></div>
|
||||
</li>
|
||||
<!-- } 상품문의 끝 -->
|
||||
|
||||
<!-- 배송/교환 시작 { -->
|
||||
<li id="sit_dex">
|
||||
<h2>배송/교환정보</h2>
|
||||
|
||||
<?php if ($default['de_baesong_content']) { // 배송정보 내용이 있다면 ?>
|
||||
<!-- 배송 시작 { -->
|
||||
<div id="sit_dvr">
|
||||
<h3>배송</h3>
|
||||
<?php echo conv_content($default['de_baesong_content'], 1); ?>
|
||||
</div>
|
||||
<!-- } 배송 끝 -->
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($default['de_change_content']) { // 교환/반품 내용이 있다면 ?>
|
||||
<!-- 교환 시작 { -->
|
||||
<div id="sit_ex" >
|
||||
<h3>교환</h3>
|
||||
<?php echo conv_content($default['de_change_content'], 1); ?>
|
||||
</div>
|
||||
<!-- } 교환 끝 -->
|
||||
<?php } ?>
|
||||
|
||||
</li>
|
||||
<!-- } 배송/교환 끝 -->
|
||||
</ul>
|
||||
</div>
|
||||
<script>
|
||||
$(function (){
|
||||
$(".tab_con>li").hide();
|
||||
$(".tab_con>li:first").show();
|
||||
$(".tab_tit li button").click(function(){
|
||||
$(".tab_tit li button").removeClass("selected");
|
||||
$(this).addClass("selected");
|
||||
$(".tab_con>li").hide();
|
||||
$($(this).attr("rel")).show();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div id="sit_buy" class="fix">
|
||||
<div class="sit_buy_inner">
|
||||
<?php if($option_item) { // 선택옵션이 있다면 ?>
|
||||
<!-- 선택옵션 시작 { -->
|
||||
<section class="sit_side_option">
|
||||
<h3>선택옵션</h3>
|
||||
<?php // 선택옵션
|
||||
echo str_replace(array('class="get_item_options"', 'id="it_option_', 'class="it_option"'), array('class="get_side_item_options"', 'id="it_side_option_', 'class="it_side_option"'), $option_item);
|
||||
?>
|
||||
</section>
|
||||
<!-- } 선택옵션 끝 -->
|
||||
<?php } // end if?>
|
||||
|
||||
<?php if ($it['it_basic']) { // 상품 기본설명 ?>
|
||||
<h3>상품 기본설명</h3>
|
||||
<div id="sit_inf_basic">
|
||||
<?php echo $it['it_basic']; ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<?php if ($it['it_explan']) { // 상품 상세설명 ?>
|
||||
<h3>상품 상세설명</h3>
|
||||
<div id="sit_inf_explan">
|
||||
<?php echo conv_content($it['it_explan'], 1); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
|
||||
<?php
|
||||
if ($it['it_info_value']) { // 상품 정보 고시
|
||||
$info_data = unserialize(stripslashes($it['it_info_value']));
|
||||
if(is_array($info_data)) {
|
||||
$gubun = $it['it_info_gubun'];
|
||||
$info_array = $item_info[$gubun]['article'];
|
||||
?>
|
||||
<h3>상품 정보 고시</h3>
|
||||
<table id="sit_inf_open">
|
||||
<colgroup>
|
||||
<col class="grid_4">
|
||||
<col>
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<?php
|
||||
foreach($info_data as $key=>$val) {
|
||||
$ii_title = $info_array[$key][0];
|
||||
$ii_value = $val;
|
||||
?>
|
||||
<tr>
|
||||
<th scope="row"><?php echo $ii_title; ?></th>
|
||||
<td><?php echo $ii_value; ?></td>
|
||||
</tr>
|
||||
<?php } //foreach?>
|
||||
</tbody>
|
||||
</table>
|
||||
<!-- 상품정보고시 end -->
|
||||
<?php
|
||||
} else {
|
||||
if($is_admin) {
|
||||
echo '<p>상품 정보 고시 정보가 올바르게 저장되지 않았습니다.<br>config.php 파일의 G5_ESCAPE_FUNCTION 설정을 addslashes 로<br>변경하신 후 관리자 > 상품정보 수정에서 상품 정보를 다시 저장해주세요. </p>';
|
||||
}
|
||||
}
|
||||
} //if
|
||||
?>
|
||||
<?php if($supply_item) { // 추가옵션이 있다면 ?>
|
||||
<!-- 추가옵션 시작 { -->
|
||||
<section class="sit_side_option">
|
||||
<h3>추가옵션</h3>
|
||||
<?php // 추가옵션
|
||||
echo str_replace(array('id="it_supply_', 'class="it_supply"'), array('id="it_side_supply_', 'class="it_side_supply"'), $supply_item);
|
||||
?>
|
||||
</section>
|
||||
<!-- } 추가옵션 끝 -->
|
||||
<?php } // end if?>
|
||||
|
||||
<?php if ($is_orderable) { ?>
|
||||
<!-- 선택된 옵션 시작 { -->
|
||||
<section class="sit_sel_option">
|
||||
<h3>선택된 옵션</h3>
|
||||
<ul class="sit_opt_added">
|
||||
<?php if( !$option_item ){ ?>
|
||||
<li>
|
||||
<div class="opt_name">
|
||||
<span class="sit_opt_subj"><?php echo $it['it_name']; ?></span>
|
||||
</div>
|
||||
<div class="opt_count">
|
||||
<label for="ct_qty_<?php echo $i; ?>" class="sound_only">수량</label>
|
||||
<button type="button" class="sit_qty_minus"><i class="fa fa-minus" aria-hidden="true"></i><span class="sound_only">감소</span></button>
|
||||
<input type="text" name="ct_copy_qty[<?php echo $it_id; ?>][]" value="<?php echo $it['it_buy_min_qty']; ?>" id="ct_qty_<?php echo $i; ?>" class="num_input" size="5">
|
||||
<button type="button" class="sit_qty_plus"><i class="fa fa-plus" aria-hidden="true"></i><span class="sound_only">증가</span></button>
|
||||
<span class="sit_opt_prc">+0원</span>
|
||||
</div>
|
||||
</li>
|
||||
<?php } ?>
|
||||
</ul>
|
||||
</section>
|
||||
<!-- } 선택된 옵션 끝 -->
|
||||
|
||||
<div class="sum_section">
|
||||
<div class="sit_tot_price"></div>
|
||||
|
||||
<div class="sit_order_btn">
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="장바구니" class="sit_btn_cart">장바구니</button>
|
||||
<button type="submit" onclick="document.pressed=this.value;" value="바로구매" class="sit_btn_buy">바로구매</button>
|
||||
</div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<!-- } 상품 정보 끝 -->
|
||||
|
||||
<!-- 사용후기 시작 { -->
|
||||
<section id="sit_use">
|
||||
<h2>사용후기</h2>
|
||||
<?php echo pg_anchor('use'); ?>
|
||||
|
||||
<div id="itemuse"><?php include_once(G5_SHOP_PATH.'/itemuse.php'); ?></div>
|
||||
</section>
|
||||
<!-- } 사용후기 끝 -->
|
||||
|
||||
<!-- 상품문의 시작 { -->
|
||||
<section id="sit_qa">
|
||||
<h2>상품문의</h2>
|
||||
<?php echo pg_anchor('qa'); ?>
|
||||
|
||||
<div id="itemqa"><?php include_once(G5_SHOP_PATH.'/itemqa.php'); ?></div>
|
||||
</section>
|
||||
<!-- } 상품문의 끝 -->
|
||||
|
||||
<?php if ($default['de_baesong_content']) { // 배송정보 내용이 있다면 ?>
|
||||
<!-- 배송정보 시작 { -->
|
||||
<section id="sit_dvr">
|
||||
<h2>배송정보</h2>
|
||||
<?php echo pg_anchor('dvr'); ?>
|
||||
|
||||
<?php echo conv_content($default['de_baesong_content'], 1); ?>
|
||||
</section>
|
||||
<!-- } 배송정보 끝 -->
|
||||
<?php } ?>
|
||||
|
||||
|
||||
<?php if ($default['de_change_content']) { // 교환/반품 내용이 있다면 ?>
|
||||
<!-- 교환/반품 시작 { -->
|
||||
<section id="sit_ex">
|
||||
<h2>교환/반품</h2>
|
||||
<?php echo pg_anchor('ex'); ?>
|
||||
|
||||
<?php echo conv_content($default['de_change_content'], 1); ?>
|
||||
</section>
|
||||
<!-- } 교환/반품 끝 -->
|
||||
<?php } ?>
|
||||
|
||||
|
||||
<script>
|
||||
$(window).on("load", function() {
|
||||
$("#sit_inf_explan").viewimageresize2();
|
||||
jQuery(function($){
|
||||
var change_name = "ct_copy_qty";
|
||||
|
||||
$(document).on("select_it_option_change", "select.it_option", function(e, $othis) {
|
||||
var value = $othis.val(),
|
||||
change_id = $othis.attr("id").replace("it_option_", "it_side_option_");
|
||||
|
||||
if( $("#"+change_id).length ){
|
||||
$("#"+change_id).val(value).attr("selected", "selected");
|
||||
}
|
||||
});
|
||||
|
||||
$(document).on("select_it_option_post", "select.it_option", function(e, $othis, idx, sel_count, data) {
|
||||
var value = $othis.val(),
|
||||
change_id = $othis.attr("id").replace("it_option_", "it_side_option_");
|
||||
|
||||
$("select.it_side_option").eq(idx+1).empty().html(data).attr("disabled", false);
|
||||
|
||||
// select의 옵션이 변경됐을 경우 하위 옵션 disabled
|
||||
if( (idx+1) < sel_count) {
|
||||
$("select.it_side_option:gt("+(idx+1)+")").val("").attr("disabled", true);
|
||||
}
|
||||
});
|
||||
|
||||
$(document).on("add_sit_sel_option", "#sit_sel_option", function(e, opt) {
|
||||
|
||||
opt = opt.replace('name="ct_qty[', 'name="'+change_name+'[');
|
||||
|
||||
var $opt = $(opt);
|
||||
$opt.removeClass("sit_opt_list");
|
||||
$("input[type=hidden]", $opt).remove();
|
||||
|
||||
$(".sit_sel_option .sit_opt_added").append($opt);
|
||||
|
||||
});
|
||||
|
||||
$(document).on("price_calculate", "#sit_tot_price", function(e, total) {
|
||||
|
||||
$(".sum_section .sit_tot_price").empty().html("<span>총 금액 </span><strong>"+number_format(String(total))+"</strong> 원");
|
||||
|
||||
});
|
||||
|
||||
$(".sit_side_option").on("change", "select.it_side_option", function(e) {
|
||||
var idx = $("select.it_side_option").index($(this)),
|
||||
value = $(this).val();
|
||||
|
||||
if( value ){
|
||||
if (typeof(option_add) != "undefined"){
|
||||
option_add = true;
|
||||
}
|
||||
|
||||
$("select.it_option").eq(idx).val(value).attr("selected", "selected").trigger("change");
|
||||
}
|
||||
});
|
||||
|
||||
$(".sit_side_option").on("change", "select.it_side_supply", function(e) {
|
||||
var value = $(this).val();
|
||||
|
||||
if( value ){
|
||||
if (typeof(supply_add) != "undefined"){
|
||||
supply_add = true;
|
||||
}
|
||||
|
||||
$("select.it_supply").val(value).attr("selected", "selected").trigger("change");
|
||||
}
|
||||
});
|
||||
|
||||
$(".sit_opt_added").on("click", "button", function(e){
|
||||
e.preventDefault();
|
||||
|
||||
var $this = $(this),
|
||||
mode = $this.text(),
|
||||
$sit_sel_el = $("#sit_sel_option"),
|
||||
li_parent_index = $this.closest('li').index();
|
||||
|
||||
if( ! $sit_sel_el.length ){
|
||||
alert("el 에러");
|
||||
return false;
|
||||
}
|
||||
|
||||
switch(mode) {
|
||||
case "증가":
|
||||
$sit_sel_el.find("li").eq(li_parent_index).find(".sit_qty_plus").trigger("click");
|
||||
break;
|
||||
case "감소":
|
||||
$sit_sel_el.find("li").eq(li_parent_index).find(".sit_qty_minus").trigger("click");
|
||||
break;
|
||||
case "삭제":
|
||||
$sit_sel_el.find("li").eq(li_parent_index).find(".sit_opt_del").trigger("click");
|
||||
break;
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
$(document).on("sit_sel_option_success", "#sit_sel_option li button", function(e, $othis, mode, this_qty) {
|
||||
var ori_index = $othis.closest('li').index();
|
||||
|
||||
switch(mode) {
|
||||
case "증가":
|
||||
case "감소":
|
||||
$(".sit_opt_added li").eq(ori_index).find("input[name^=ct_copy_qty]").val(this_qty);
|
||||
break;
|
||||
case "삭제":
|
||||
$(".sit_opt_added li").eq(ori_index).remove();
|
||||
break;
|
||||
}
|
||||
});
|
||||
|
||||
$(document).on("change_option_qty", "input[name^=ct_qty]", function(e, $othis, val, force_val) {
|
||||
var $this = $(this),
|
||||
ori_index = $othis.closest('li').index(),
|
||||
this_val = force_val ? force_val : val;
|
||||
|
||||
$(".sit_opt_added").find("li").eq(ori_index).find("input[name^="+change_name+"]").val(this_val);
|
||||
});
|
||||
|
||||
$(".sit_opt_added").on("keyup paste", "input[name^="+change_name+"]", function(e) {
|
||||
var $this = $(this),
|
||||
val= $this.val(),
|
||||
this_index = $("input[name^="+change_name+"]").index(this);
|
||||
|
||||
$("input[name^=ct_qty]").eq(this_index).val(val).trigger("keyup");
|
||||
});
|
||||
|
||||
$(".sit_order_btn").on("click", "button", function(e){
|
||||
e.preventDefault();
|
||||
|
||||
var $this = $(this);
|
||||
|
||||
if( $this.hasClass("sit_btn_cart") ){
|
||||
$("#sit_ov_btn .sit_btn_cart").trigger("click");
|
||||
} else if ( $this.hasClass("sit_btn_buy") ) {
|
||||
$("#sit_ov_btn .sit_btn_buy").trigger("click");
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@ -12,7 +12,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<h3>등록된 상품문의</h3>
|
||||
|
||||
<div id="sit_qa_wbtn">
|
||||
<a href="<?php echo $itemqa_form; ?>" class="btn02 itemqa_form">상품문의 쓰기<span class="sound_only"> 새 창</span></a>
|
||||
<a href="<?php echo $itemqa_form; ?>" class="btn02 itemqa_form">상품문의 쓰기<span class="sound_only">새 창</span></a>
|
||||
<a href="<?php echo $itemqa_list; ?>" id="itemqa_list" class="btn01">더보기</a>
|
||||
</div>
|
||||
|
||||
@ -65,10 +65,8 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<li class="sit_qa_li">
|
||||
<button type="button" class="sit_qa_li_title"><span class="<?php echo $iq_style; ?>"><?php echo $iq_stats; ?></span><?php echo $iq_subject; ?></button>
|
||||
<dl class="sit_qa_dl">
|
||||
<dt>작성자</dt>
|
||||
<dd><?php echo $iq_name; ?></dd>
|
||||
<dt>작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $iq_time; ?></dd>
|
||||
<dt>작성자/작성일</dt>
|
||||
<dd><?php echo $iq_name; ?><span class="st_bg"></span><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $iq_time; ?></dd>
|
||||
</dl>
|
||||
|
||||
<div id="sit_qa_con_<?php echo $i; ?>" class="sit_qa_con">
|
||||
@ -91,8 +89,6 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<div class="sit_qa_cmd">
|
||||
<a href="<?php echo $itemqa_form."&iq_id={$row['iq_id']}&w=u"; ?>" class="itemqa_form btn01" onclick="return false;">수정</a>
|
||||
<a href="<?php echo $itemqa_formupdate."&iq_id={$row['iq_id']}&w=d&hash={$hash}"; ?>" class="itemqa_delete btn01">삭제</a>
|
||||
<!-- <button type="button" onclick="javascript:itemqa_update(<?php echo $i; ?>);" class="btn01">수정</button>
|
||||
<button type="button" onclick="javascript:itemqa_delete(fitemqa_password<?php echo $i; ?>, <?php echo $i; ?>);" class="btn01">삭제</button> -->
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
@ -109,10 +105,9 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
</section>
|
||||
|
||||
<?php
|
||||
echo itemqa_page($config['cf_write_pages'], $page, $total_page, "./itemqa.php?it_id=$it_id&page=", "");
|
||||
echo itemqa_page($config['cf_write_pages'], $page, $total_page, G5_SHOP_URL."/itemqa.php?it_id=$it_id&page=", "");
|
||||
?>
|
||||
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
$(".itemqa_form").click(function(){
|
||||
|
||||
@ -9,19 +9,17 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<div id="sit_qa_write" class="new_win">
|
||||
<h1 id="win_title">상품문의 쓰기</h1>
|
||||
|
||||
<form name="fitemqa" method="post" action="./itemqaformupdate.php" onsubmit="return fitemqa_submit(this);" autocomplete="off">
|
||||
<form name="fitemqa" method="post" action="<?php echo G5_SHOP_URL;?>/itemqaformupdate.php" onsubmit="return fitemqa_submit(this);" autocomplete="off">
|
||||
<input type="hidden" name="w" value="<?php echo $w; ?>">
|
||||
<input type="hidden" name="it_id" value="<?php echo $it_id; ?>">
|
||||
<input type="hidden" name="iq_id" value="<?php echo $iq_id; ?>">
|
||||
|
||||
<div class="form_01 new_win_con">
|
||||
|
||||
<ul>
|
||||
<li>
|
||||
<li class="chk_box">
|
||||
<strong class="sound_only">옵션</strong>
|
||||
<input type="checkbox" name="iq_secret" id="iq_secret" value="1" <?php echo $chk_secret; ?>>
|
||||
<label for="iq_secret">비밀글</label>
|
||||
|
||||
<input type="checkbox" name="iq_secret" id="iq_secret" value="1" <?php echo $chk_secret; ?> class="selec_chk">
|
||||
<label for="iq_secret"><span></span>비밀글</label>
|
||||
</li>
|
||||
<li>
|
||||
<div class="form_left">
|
||||
@ -32,7 +30,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<div class="form_right">
|
||||
<label for="iq_hp" class="sound_only">휴대폰</label>
|
||||
<input type="text" name="iq_hp" id="iq_hp" value="<?php echo get_text($qa['iq_hp']); ?>" class="frm_input full_input" size="20" placeholder="휴대폰"><br>
|
||||
<span class="frm_info">휴대폰번호를 입력하시면 답변 등록 시 답변등록 알림이 SMS로 전송됩니다. </span>
|
||||
<span class="frm_info">휴대폰번호를 입력하시면 답변 등록 시 답변등록 알림이 SMS로 전송됩니다.</span>
|
||||
</div>
|
||||
</li>
|
||||
<li>
|
||||
@ -46,11 +44,10 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
</ul>
|
||||
|
||||
<div class="win_btn">
|
||||
<input type="submit" value="작성완료" class="btn_submit">
|
||||
<button type="submit" class="btn_submit">작성완료</button>
|
||||
<button type="button" onclick="self.close();" class="btn_close">닫기</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
@ -11,9 +11,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
<form method="get" action="<?php echo $_SERVER['SCRIPT_NAME']; ?>">
|
||||
<div id="sqa_sch">
|
||||
<a href="<?php echo $_SERVER['SCRIPT_NAME']; ?>">전체보기</a>
|
||||
<div class="sch_wr">
|
||||
<label for="sfl" class="sound_only">검색항목<strong class="sound_only"> 필수</strong></label>
|
||||
<label for="sfl" class="sound_only">검색항목 필수</label>
|
||||
<select name="sfl" id="sfl" required>
|
||||
<option value="">선택</option>
|
||||
<option value="b.it_name" <?php echo get_selected($sfl, "b.it_name", true); ?>>상품명</option>
|
||||
@ -23,18 +21,17 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<option value="a.iq_name" <?php echo get_selected($sfl, "a.iq_name"); ?>>작성자명</option>
|
||||
<option value="a.mb_id" <?php echo get_selected($sfl, "a.mb_id"); ?>>작성자아이디</option>
|
||||
</select>
|
||||
|
||||
<label for="stx" class="sound_only">검색어<strong class="sound_only"> 필수</strong></label>
|
||||
<input type="text" name="stx" value="<?php echo $stx; ?>" id="stx" required class=" sch_input">
|
||||
<button type="submit" value="검색" class="sch_btn"><i class="fa fa-search" aria-hidden="true"></i><span class="sound_only">검색</span></button>
|
||||
<div class="sch_wr">
|
||||
<label for="stx" class="sound_only">검색어<strong class="sound_only"> 필수</strong></label>
|
||||
<input type="text" name="stx" value="<?php echo $stx; ?>" id="stx" required class="sch_input">
|
||||
<button type="submit" value="검색" class="sch_btn"><i class="fa fa-search" aria-hidden="true"></i><span class="sound_only">검색</span></button>
|
||||
</div>
|
||||
<a href="<?php echo $_SERVER['SCRIPT_NAME']; ?>">전체보기</a>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div id="sqa">
|
||||
|
||||
<!-- <p><?php echo $config['cf_title']; ?> 전체 상품문의 목록입니다.</p> -->
|
||||
|
||||
<?php
|
||||
$thumbnail_width = 500;
|
||||
$num = $total_count - ($page - 1) * $rows;
|
||||
@ -57,7 +54,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
$iq_question = get_view_thumbnail(conv_content($row['iq_question'], 1), $thumbnail_width);
|
||||
}
|
||||
|
||||
$it_href = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$it_href = shop_item_url($row['it_id']);
|
||||
|
||||
if ($row['iq_answer'])
|
||||
{
|
||||
@ -75,23 +72,22 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
if ($i == 0) echo '<ol>';
|
||||
?>
|
||||
<li>
|
||||
|
||||
<div class="sqa_img">
|
||||
<a href="<?php echo $it_href; ?>">
|
||||
<?php echo get_it_image($row['it_id'], 100, 100); ?>
|
||||
<?php echo get_it_image($row['it_id'], 50, 50); ?>
|
||||
<span><?php echo $row['it_name']; ?></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<section class="sqa_section">
|
||||
<h2><span class="<?php echo $iq_style; ?>"><?php echo $iq_stats; ?></span><?php echo $iq_subject; ?></h2>
|
||||
|
||||
<h2><?php echo $iq_subject; ?></h2>
|
||||
<span class="<?php echo $iq_style; ?>"><?php echo $iq_stats; ?></span>
|
||||
|
||||
<dl class="sqa_dl">
|
||||
<dt class="sound_only">작성자</dt>
|
||||
<dd><i class="fa fa-user" aria-hidden="true"></i> <?php echo $row['iq_name']; ?></dd>
|
||||
<dt class="sound_only">작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo substr($row['iq_time'],0,10); ?></dd>
|
||||
|
||||
</dl>
|
||||
|
||||
<div id="sqa_con_<?php echo $i; ?>" class="sqa_con" style="display:none;">
|
||||
|
||||
@ -13,16 +13,15 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
<div class="sit_use_top">
|
||||
<?php if ($star_score) { ?>
|
||||
<h4>고객 평점</h4>
|
||||
<h4>구매고객 총평점 <span>(총 <strong><?php echo $total_count; ?></strong> 건 상품평 기준)</span></h4>
|
||||
<img src="<?php echo G5_SHOP_URL; ?>/img/s_star<?php echo $star_score?>.png" alt="" class="sit_star">
|
||||
<span class="st_bg "></span>
|
||||
총 <strong><?php echo $total_count; ?></strong> 건 사용후기
|
||||
<?php } ?>
|
||||
<div id="sit_use_wbtn">
|
||||
<a href="<?php echo $itemuse_form; ?>" class="btn02 itemuse_form">사용후기 쓰기<span class="sound_only"> 새 창</span></a>
|
||||
<a href="<?php echo $itemuse_list; ?>" class="btn01 itemuse_list">더보기</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
$thumbnail_width = 500;
|
||||
|
||||
@ -45,21 +44,20 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
?>
|
||||
|
||||
<li class="sit_use_li">
|
||||
<div class="sit_use_tit"><?php echo $is_subject; ?></div>
|
||||
<button type="button" class="sit_use_li_title">내용보기 <i class="fa fa-caret-down" aria-hidden="true"></i></button>
|
||||
<dl class="sit_use_dl">
|
||||
<dt>평점<dt>
|
||||
<dd class="sit_use_star"><img src="<?php echo G5_SHOP_URL; ?>/img/s_star<?php echo $is_star; ?>.png" alt="별<?php echo $is_star; ?>개" width="85"></dd>
|
||||
<dt>작성자</dt>
|
||||
<dd><?php echo $is_name; ?></dd>
|
||||
<dt>작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $is_time; ?></dd>
|
||||
</dl>
|
||||
<span class="sit_thum"><?php echo get_itemuselist_thumbnail($row['it_id'], $row['is_content'], 100, 100); ?></span>
|
||||
<dl class="sit_use_dl">
|
||||
<dt>평점<dt>
|
||||
<dd class="sit_use_star"><img src="<?php echo G5_SHOP_URL; ?>/img/s_star<?php echo $is_star; ?>.png" alt="별<?php echo $is_star; ?>개" width="85"></dd>
|
||||
<dt></dt>
|
||||
<dd class="sit_use_tit"><?php echo $is_subject; ?></dd>
|
||||
<dt>작성자/작성일</dt>
|
||||
<dd><?php echo $is_name; ?><span class="st_bg"></span><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $is_time; ?></dd>
|
||||
</dl>
|
||||
<button type="button" class="sit_use_li_title">내용보기 <i class="fa fa-caret-down" aria-hidden="true"></i></button>
|
||||
|
||||
<div id="sit_use_con_<?php echo $i; ?>" class="sit_use_con">
|
||||
<div class="sit_use_p">
|
||||
<?php echo $is_content; // 사용후기 내용 ?>
|
||||
|
||||
<?php echo $is_content; // 사용후기 내용 ?>
|
||||
</div>
|
||||
|
||||
<?php if ($is_admin || $row['mb_id'] == $member['mb_id']) { ?>
|
||||
@ -95,7 +93,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
</section>
|
||||
|
||||
<?php
|
||||
echo itemuse_page($config['cf_write_pages'], $page, $total_page, "./itemuse.php?it_id=$it_id&page=", "");
|
||||
echo itemuse_page($config['cf_write_pages'], $page, $total_page, G5_SHOP_URL."/itemuse.php?it_id=$it_id&page=", "");
|
||||
?>
|
||||
|
||||
<script>
|
||||
|
||||
@ -9,13 +9,12 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<div id="sit_use_write" class="new_win">
|
||||
<h1 id="win_title">사용후기 쓰기</h1>
|
||||
|
||||
<form name="fitemuse" method="post" action="./itemuseformupdate.php" onsubmit="return fitemuse_submit(this);" autocomplete="off">
|
||||
<form name="fitemuse" method="post" action="<?php echo G5_SHOP_URL;?>/itemuseformupdate.php" onsubmit="return fitemuse_submit(this);" autocomplete="off">
|
||||
<input type="hidden" name="w" value="<?php echo $w; ?>">
|
||||
<input type="hidden" name="it_id" value="<?php echo $it_id; ?>">
|
||||
<input type="hidden" name="is_id" value="<?php echo $is_id; ?>">
|
||||
|
||||
<div class="new_win_con form_01">
|
||||
|
||||
<ul>
|
||||
<li>
|
||||
<label for="is_subject" class="sound_only">제목<strong> 필수</strong></label>
|
||||
@ -27,30 +26,30 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
</li>
|
||||
<li>
|
||||
<span class="sound_only">평점</span>
|
||||
<ul id="sit_use_write_star">
|
||||
<ul id="sit_use_write_star" class="chk_box">
|
||||
<li>
|
||||
<input type="radio" name="is_score" value="5" id="is_score5" <?php echo ($is_score==5)?'checked="checked"':''; ?>>
|
||||
<label for="is_score5">매우만족</label>
|
||||
<label for="is_score5"><span></span>매우만족</label>
|
||||
<img src="<?php echo G5_URL; ?>/shop/img/s_star5.png" alt="매우만족">
|
||||
</li>
|
||||
<li>
|
||||
<input type="radio" name="is_score" value="4" id="is_score4" <?php echo ($is_score==4)?'checked="checked"':''; ?>>
|
||||
<label for="is_score4">만족</label>
|
||||
<label for="is_score4"><span></span>만족</label>
|
||||
<img src="<?php echo G5_URL; ?>/shop/img/s_star4.png" alt="만족">
|
||||
</li>
|
||||
<li>
|
||||
<input type="radio" name="is_score" value="3" id="is_score3" <?php echo ($is_score==3)?'checked="checked"':''; ?>>
|
||||
<label for="is_score3">보통</label>
|
||||
<label for="is_score3"><span></span>보통</label>
|
||||
<img src="<?php echo G5_URL; ?>/shop/img/s_star3.png" alt="보통">
|
||||
</li>
|
||||
<li>
|
||||
<input type="radio" name="is_score" value="2" id="is_score2" <?php echo ($is_score==2)?'checked="checked"':''; ?>>
|
||||
<label for="is_score2">불만</label>
|
||||
<label for="is_score2"><span></span>불만</label>
|
||||
<img src="<?php echo G5_URL; ?>/shop/img/s_star2.png" alt="불만">
|
||||
</li>
|
||||
<li>
|
||||
<input type="radio" name="is_score" value="1" id="is_score1" <?php echo ($is_score==1)?'checked="checked"':''; ?>>
|
||||
<label for="is_score1">매우불만</label>
|
||||
<label for="is_score1"><span></span>매우불만</label>
|
||||
<img src="<?php echo G5_URL; ?>/shop/img/s_star1.png" alt="매우불만">
|
||||
</li>
|
||||
</ul>
|
||||
@ -58,11 +57,10 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
</ul>
|
||||
|
||||
<div class="win_btn">
|
||||
<input type="submit" value="작성완료" class="btn_submit">
|
||||
<button type="submit" class="btn_submit">작성완료</button>
|
||||
<button type="button" onclick="self.close();" class="btn_close">닫기</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
@ -10,9 +10,7 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<!-- 전체 상품 사용후기 목록 시작 { -->
|
||||
<form method="get" action="<?php echo $_SERVER['SCRIPT_NAME']; ?>">
|
||||
<div id="sps_sch">
|
||||
<a href="<?php echo $_SERVER['SCRIPT_NAME']; ?>">전체보기</a>
|
||||
<div class="sch_wr">
|
||||
<label for="sfl" class="sound_only">검색항목<strong class="sound_only"> 필수</strong></label>
|
||||
<label for="sfl" class="sound_only">검색항목 필수</label>
|
||||
<select name="sfl" id="sfl" required>
|
||||
<option value="">선택</option>
|
||||
<option value="b.it_name" <?php echo get_selected($sfl, "b.it_name"); ?>>상품명</option>
|
||||
@ -22,17 +20,17 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<option value="a.is_name" <?php echo get_selected($sfl, "a.is_name"); ?>>작성자명</option>
|
||||
<option value="a.mb_id" <?php echo get_selected($sfl, "a.mb_id"); ?>>작성자아이디</option>
|
||||
</select>
|
||||
<label for="stx" class="sound_only">검색어<strong class="sound_only"> 필수</strong></label>
|
||||
<input type="text" name="stx" value="<?php echo $stx; ?>" id="stx" required class="sch_input">
|
||||
<button type="submit" value="검색" class="sch_btn"><i class="fa fa-search" aria-hidden="true"></i><span class="sound_only">검색</span></button>
|
||||
<div class="sch_wr">
|
||||
<label for="stx" class="sound_only">검색어<strong class="sound_only"> 필수</strong></label>
|
||||
<input type="text" name="stx" value="<?php echo $stx; ?>" id="stx" required class="sch_input">
|
||||
<button type="submit" value="검색" class="sch_btn"><i class="fa fa-search" aria-hidden="true"></i><span class="sound_only">검색</span></button>
|
||||
</div>
|
||||
<a href="<?php echo $_SERVER['SCRIPT_NAME']; ?>">전체보기</a>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<div id="sps">
|
||||
|
||||
<!-- <p><?php echo $config['cf_title']; ?> 전체 사용후기 목록입니다.</p> -->
|
||||
|
||||
<?php
|
||||
$thumbnail_width = 500;
|
||||
|
||||
@ -43,71 +41,94 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
$is_content = get_view_thumbnail(conv_content($row['is_content'], 1), $thumbnail_width);
|
||||
|
||||
$row2 = sql_fetch(" select it_name from {$g5['g5_shop_item_table']} where it_id = '{$row['it_id']}' ");
|
||||
$it_href = G5_SHOP_URL."/item.php?it_id={$row['it_id']}";
|
||||
$row2 = get_shop_item($row['it_id'], true);
|
||||
$it_href = shop_item_url($row['it_id']);
|
||||
|
||||
if ($i == 0) echo '<ol>';
|
||||
?>
|
||||
<li>
|
||||
|
||||
<div class="sps_img">
|
||||
<a href="<?php echo $it_href; ?>">
|
||||
<?php echo get_itemuselist_thumbnail($row['it_id'], $row['is_content'], 100, 100); ?>
|
||||
<span><?php echo $row2['it_name']; ?></span>
|
||||
</a>
|
||||
<div class="sps_img_inner">
|
||||
<a href="<?php echo $it_href; ?>">
|
||||
<?php echo get_it_image($row['it_id'], 100, 100); ?>
|
||||
<span><?php echo $row2['it_name']; ?></span>
|
||||
</a>
|
||||
<button class="prd_detail" data-url="<?php echo G5_SHOP_URL.'/largeimage.php?it_id='.$row['it_id']; ?>"><i class="fa fa-camera" aria-hidden="true"></i><span class="sound_only">상품 이미지보기</span></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="sps_section">
|
||||
<span class="sound_only">평가점수</span>
|
||||
<span><img src="<?php echo G5_URL; ?>/shop/img/s_star<?php echo $star; ?>.png" alt="별<?php echo $star; ?>개" width="80"></span>
|
||||
|
||||
<span class="sps_pd_name"><?php echo get_text($row2['it_name']); ?></span>
|
||||
<span class="sps_rv_tit"><?php echo get_text($row['is_subject']); ?></span>
|
||||
<span class="sps_rv_thum"><?php echo get_itemuse_thumb($row['is_content'], 60, 60); ?></span>
|
||||
|
||||
<div class="sps_con_btn">
|
||||
<dl class="sps_dl">
|
||||
<dt class="sound_only">작성자</dt>
|
||||
<dd><i class="fa fa-user" aria-hidden="true"></i> <?php echo $row['is_name']; ?></dd>
|
||||
<dt class="sound_only">작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo substr($row['is_time'],0,10); ?></dd>
|
||||
</dl>
|
||||
|
||||
<button class="sps_con_<?php echo $i; ?> review_detail">내용보기</button>
|
||||
|
||||
<!-- 사용후기 자세히 시작 -->
|
||||
<div class="review_detail_cnt">
|
||||
<div class="review_detail_in">
|
||||
<h3>사용후기</h3>
|
||||
<div class="review_cnt">
|
||||
<div class="review_tp_cnt">
|
||||
<span><?php echo get_text($row['is_subject']); ?></span>
|
||||
<dl class="sps_dl">
|
||||
<dt class="sound_only">작성자</dt>
|
||||
<dd><i class="fa fa-user" aria-hidden="true"></i> <?php echo $row['is_name']; ?></dd>
|
||||
<dt class="sound_only">작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo substr($row['is_time'],0,10); ?></dd>
|
||||
</dl>
|
||||
</div>
|
||||
<div class="review_summ">
|
||||
<?php echo get_it_image($row['it_id'], 50, 50); ?>
|
||||
<span><?php echo get_text($row2['it_name']); ?></span>
|
||||
<span class="sound_only">평가점수</span><img src="<?php echo G5_URL; ?>/shop/img/s_star<?php echo $star; ?>.png" alt="별<?php echo $star; ?>개" width="80">
|
||||
</div>
|
||||
|
||||
<div id="sps_con_<?php echo $i; ?>" class="review_bt_cnt">
|
||||
<?php echo $is_content; // 사용후기 내용 ?>
|
||||
<?php
|
||||
if( !empty($row['is_reply_subject']) ){ //사용후기 답변이 있다면
|
||||
$is_reply_content = get_view_thumbnail(conv_content($row['is_reply_content'], 1), $thumbnail_width);
|
||||
?>
|
||||
<div class="sps_reply">
|
||||
<div class="sps_img">
|
||||
<a href="<?php echo $it_href; ?>">
|
||||
<?php echo get_itemuselist_thumbnail($row['it_id'], $row['is_reply_content'], 50, 50); ?>
|
||||
<span><?php echo $row2['it_name']; ?></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<section>
|
||||
<h2 class="is_use_reply"><?php echo get_text($row['is_reply_subject']); ?></h2>
|
||||
<div class="sps_dl">
|
||||
<i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $row['is_reply_name']; ?>
|
||||
</div>
|
||||
<div id="sps_con_<?php echo $i; ?>_reply" style="display:none;">
|
||||
<?php echo $is_reply_content; // 사용후기 답변 내용 ?>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
<?php } //end if ?>
|
||||
</div>
|
||||
</div>
|
||||
<button class="rd_cls"><span class="sound_only">후기 상세보기 팝업 닫기</span><i class="fa fa-times" aria-hidden="true"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 사용후기 자세히 끝 -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<section class="sps_section">
|
||||
<h2><?php echo get_text($row['is_subject']); ?></h2>
|
||||
|
||||
<dl class="sps_dl">
|
||||
<dt class="sound_only">평가점수</dt>
|
||||
<dd><img src="<?php echo G5_URL; ?>/shop/img/s_star<?php echo $star; ?>.png" alt="별<?php echo $star; ?>개" width="80"></dd>
|
||||
<dt class="sound_only">작성자</dt>
|
||||
<dd><i class="fa fa-user" aria-hidden="true"></i> <?php echo $row['is_name']; ?></dd>
|
||||
<dt class="sound_only">작성일</dt>
|
||||
<dd><i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo substr($row['is_time'],0,10); ?></dd>
|
||||
|
||||
</dl>
|
||||
|
||||
<div id="sps_con_<?php echo $i; ?>" style="display:none;">
|
||||
<?php echo $is_content; // 사용후기 내용 ?>
|
||||
<?php
|
||||
if( !empty($row['is_reply_subject']) ){ //사용후기 답변이 있다면
|
||||
$is_reply_content = get_view_thumbnail(conv_content($row['is_reply_content'], 1), $thumbnail_width);
|
||||
?>
|
||||
<div class="sps_reply">
|
||||
<div class="sps_img">
|
||||
<a href="<?php echo $it_href; ?>">
|
||||
<?php echo get_itemuselist_thumbnail($row['it_id'], $row['is_reply_content'], 50, 50); ?>
|
||||
<span><?php echo $row2['it_name']; ?></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<section>
|
||||
|
||||
<h2 class="is_use_reply"><?php echo get_text($row['is_reply_subject']); ?></h2>
|
||||
|
||||
<div class="sps_dl">
|
||||
<i class="fa fa-clock-o" aria-hidden="true"></i> <?php echo $row['is_reply_name']; ?>
|
||||
</div>
|
||||
|
||||
<div id="sps_con_<?php echo $i; ?>_reply" style="display:none;">
|
||||
<?php echo $is_reply_content; // 사용후기 답변 내용 ?>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</div>
|
||||
<?php } //end if ?>
|
||||
</div>
|
||||
|
||||
<div class="sps_con_btn"><button class="sps_con_<?php echo $i; ?>">내용보기 <i class="fa fa-caret-down" aria-hidden="true"></i></button></div>
|
||||
</section>
|
||||
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<?php }
|
||||
if ($i > 0) echo '</ol>';
|
||||
if ($i == 0) echo '<p id="sps_empty">자료가 없습니다.</p>';
|
||||
@ -117,25 +138,35 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
<?php echo get_paging($config['cf_write_pages'], $page, $total_page, "{$_SERVER['SCRIPT_NAME']}?$qstr&page="); ?>
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
// 사용후기 더보기
|
||||
$(".sps_con_btn button").click(function(){
|
||||
var $con = $(this).parent().prev();
|
||||
if($con.is(":visible")) {
|
||||
$con.slideUp();
|
||||
$(this).html("내용보기 <i class=\"fa fa-caret-down\" aria-hidden=\"true\"></i>");
|
||||
} else {
|
||||
$(".sps_con_btn button").html("내용보기 <i class=\"fa fa-caret-down\" aria-hidden=\"true\"></i>");
|
||||
$("div[id^=sps_con]:visible").hide();
|
||||
$con.slideDown(
|
||||
function() {
|
||||
// 이미지 리사이즈
|
||||
$con.viewimageresize2();
|
||||
}
|
||||
);
|
||||
$(this).html("내용닫기 <i class=\"fa fa-caret-up\" aria-hidden=\"true\"></i>");
|
||||
}
|
||||
jQuery(function($){
|
||||
// 사용후기 열기
|
||||
$(".review_detail").on("click", function(){
|
||||
$(this).parent("div").children(".review_detail_cnt").show();
|
||||
});
|
||||
|
||||
// 사용후기 닫기
|
||||
$(document).mouseup(function (e){
|
||||
var container = $(".review_detail_cnt");
|
||||
if( container.has(e.target).length === 0)
|
||||
container.hide();
|
||||
});
|
||||
|
||||
// 후기 상세 글쓰기 닫기
|
||||
$('.rd_cls').click(function(){
|
||||
$('.review_detail_cnt').hide();
|
||||
});
|
||||
|
||||
// 상품이미지 크게보기
|
||||
$(".prd_detail").click(function() {
|
||||
var url = $(this).attr("data-url");
|
||||
var top = 10;
|
||||
var left = 10;
|
||||
var opt = 'scrollbars=yes,top='+top+',left='+left;
|
||||
popup_window(url, "largeimage", opt);
|
||||
|
||||
return false;
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
<!-- } 전체 상품 사용후기 목록 끝 -->
|
||||
@ -7,30 +7,20 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
<div id="sit_pvi_nw" class="new_win">
|
||||
<h1 id="win_title">상품 이미지 새창 보기</h1>
|
||||
|
||||
<div id="sit_pvi_nwbig">
|
||||
<?php
|
||||
$thumbnails = array();
|
||||
for($i=1; $i<=10; $i++) {
|
||||
if(!$row['it_img'.$i])
|
||||
continue;
|
||||
|
||||
$file = G5_DATA_PATH.'/item/'.$row['it_img'.$i];
|
||||
if(is_file($file)) {
|
||||
// 썸네일
|
||||
$thumb = get_it_thumbnail($row['it_img'.$i], 60, 60);
|
||||
$thumbnails[$i] = $thumb;
|
||||
$imageurl = G5_DATA_URL.'/item/'.$row['it_img'.$i];
|
||||
$images = get_item_images_info($row, $size, 60, 60); // 숫자값은 썸네일 width, height
|
||||
|
||||
foreach((array) $images as $i=>$imgs){
|
||||
$thumbnails[$i] = $imgs['thumb'];
|
||||
?>
|
||||
<span>
|
||||
<a href="javascript:window.close();">
|
||||
<img src="<?php echo $imageurl; ?>" width="<?php echo $size[0]; ?>" height="<?php echo $size[1]; ?>" alt="<?php echo $row['it_name']; ?>" id="largeimage_<?php echo $i; ?>">
|
||||
<?php echo $imgs['imagehtml']; ?>
|
||||
</a>
|
||||
</span>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
@ -44,23 +34,55 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
echo '</ul>';
|
||||
}
|
||||
?>
|
||||
|
||||
<div class="win_btn">
|
||||
<button type="button" onclick="javascript:window.close();" class="btn_close">창닫기</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// 창 사이즈 조절
|
||||
$(window).on("load", function() {
|
||||
var w = <?php echo $size[0]; ?> + 50;
|
||||
jQuery(function($){
|
||||
|
||||
$.fn.imgLoad = function(callback) {
|
||||
return this.each(function() {
|
||||
if (callback) {
|
||||
if (this.complete || /*for IE 10-*/ $(this).height() > 0) {
|
||||
callback.apply(this);
|
||||
}
|
||||
else {
|
||||
$(this).on('load', function(){
|
||||
callback.apply(this);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
function largeimage_load(image_width){
|
||||
var w = image_width + 50;
|
||||
var h = $("#sit_pvi_nw").outerHeight(true) + $("#sit_pvi_nw h1").outerHeight(true);
|
||||
window.resizeTo(w, h);
|
||||
});
|
||||
}
|
||||
|
||||
$(function(){
|
||||
$("#sit_pvi_nwbig span:eq("+<?php echo ($no - 1); ?>+")").addClass("visible");
|
||||
|
||||
// 창 사이즈 조절
|
||||
<?php if( isset($size[0]) && $size[0] ){ ?>
|
||||
$(window).on("load", function() {
|
||||
largeimage_load(<?php echo $size[0]; ?>);
|
||||
});
|
||||
<?php } else { ?>
|
||||
var is_load_end = false;
|
||||
$("#sit_pvi_nwbig img").imgLoad(function(){
|
||||
$(this).css({'max-width': '800px', 'height':'auto'});
|
||||
var image_width = $(this).width();
|
||||
|
||||
if( image_width && ! is_load_end ){
|
||||
largeimage_load( image_width );
|
||||
is_load_end = true;
|
||||
}
|
||||
});
|
||||
<?php } ?>
|
||||
|
||||
// 이미지 미리보기
|
||||
$(".img_thumb").bind("mouseover focus", function(){
|
||||
var idx = $(".img_thumb").index($(this));
|
||||
|
||||
@ -3,33 +3,48 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
// 장바구니 또는 위시리스트 ajax 스크립트
|
||||
add_javascript('<script src="'.G5_THEME_JS_URL.'/theme.shop.list.js"></script>', 10);
|
||||
?>
|
||||
|
||||
<!-- 상품진열 10 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$this->list_mod == 0) $sct_last = 'sct_last'; // 줄 마지막
|
||||
else if ($i%$this->list_mod == 1) $sct_last = 'sct_clear'; // 줄 첫번째
|
||||
else $sct_last = '';
|
||||
} else { // 1줄 이미지 : 1개
|
||||
$sct_last = 'sct_clear';
|
||||
}
|
||||
$i = 0;
|
||||
|
||||
if ($i == 1) {
|
||||
$this->view_star = (method_exists($this, 'view_star')) ? $this->view_star : true;
|
||||
|
||||
foreach((array) $list as $row){
|
||||
if( empty($row) ) continue;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']); // 상품링크
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : ''; //사용자후기 평균별점
|
||||
$list_mod = $this->list_mod; // 분류관리에서 1줄당 이미지 수 값 또는 파일에서 지정한 가로 수
|
||||
$is_soldout = is_soldout($row['it_id'], true); // 품절인지 체크
|
||||
|
||||
$classes = array();
|
||||
|
||||
$classes[] = 'col-row-'.$list_mod;
|
||||
|
||||
if( $i && ($i % $list_mod == 0) ){
|
||||
$classes[] = 'row-clear';
|
||||
}
|
||||
|
||||
$i++; // 변수 i 를 증가
|
||||
|
||||
if ($i === 1) {
|
||||
if ($this->css) {
|
||||
echo "<ul class=\"{$this->css}\">\n";
|
||||
} else {
|
||||
echo "<ul class=\"sct sct_10\">\n";
|
||||
echo "<ul class=\"sct sct_10 lists-row\">\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "<li class=\"sct_li {$sct_last}\" style=\"width:{$this->img_width}px\">\n";
|
||||
|
||||
echo "<div class=\"sct_img\">\n";
|
||||
|
||||
echo "<li class=\"sct_li ".implode(' ', $classes)."\" data-css=\"nocss\" style=\"height:auto\">\n";
|
||||
echo "<div class=\"sct_img\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -39,27 +54,36 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->href) {
|
||||
echo "</a>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
|
||||
if ( !$is_soldout ){ // 품절 상태가 아니면 출력합니다.
|
||||
echo "<div class=\"sct_btn list-10-btn\">
|
||||
<button type=\"button\" class=\"btn_cart sct_cart\" data-it_id=\"{$row['it_id']}\"><i class=\"fa fa-shopping-cart\" aria-hidden=\"true\"></i> 장바구니</button>\n";
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
echo "<div class=\"cart-layer\"></div>\n";
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
// 품절
|
||||
if ($is_soldout) {
|
||||
echo '<span class="shop_icon_soldout"><span class="soldout_txt">SOLD OUT</span></span>';
|
||||
}
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
|
||||
echo "<div class=\"sct_ct_wrap\">\n";
|
||||
|
||||
// 사용후기 평점표시
|
||||
if ($this->view_star && $star_score) {
|
||||
echo "<div class=\"sct_star\"><span class=\"sound_only\">고객평점</span><img src=\"".G5_SHOP_URL."/img/s_star".$star_score.".png\" alt=\"별점 ".$star_score."점\" class=\"sit_star\"></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -69,38 +93,72 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
echo "<div class=\"sct_basic\">".stripslashes($row['it_basic'])."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
echo "<div class=\"sct_bottom\">\n";
|
||||
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<span class=\"sct_discount\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
// 위시리스트 + 공유 버튼 시작
|
||||
echo "<div class=\"sct_op_btn\">\n";
|
||||
echo "<button type=\"button\" class=\"btn_wish\" data-it_id=\"{$row['it_id']}\"><span class=\"sound_only\">위시리스트</span><i class=\"fa fa-heart-o\" aria-hidden=\"true\"></i></button>\n";
|
||||
echo "<button type=\"button\" class=\"btn_share\"><span class=\"sound_only\">공유하기</span><i class=\"fa fa-share-alt\" aria-hidden=\"true\"></i></button>\n";
|
||||
|
||||
echo "<div class=\"sct_sns_wrap\">";
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo "<h3>SNS 공유</h3>";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "<button type=\"button\" class=\"sct_sns_cls\"><span class=\"sound_only\">닫기</span><i class=\"fa fa-times\" aria-hidden=\"true\"></i></button>";
|
||||
echo "</div>\n";
|
||||
}
|
||||
echo "<div class=\"sct_sns_bg\"></div>";
|
||||
echo "</div></div>\n";
|
||||
// 위시리스트 + 공유 버튼 끝
|
||||
|
||||
echo "</div>";
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sit_icon_li\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
echo "</li>\n";
|
||||
}
|
||||
} //end foreach
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i === 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 10 끝 -->
|
||||
<!-- } 상품진열 10 끝 -->
|
||||
|
||||
<script>
|
||||
//SNS 공유
|
||||
$(function (){
|
||||
$(".btn_share").on("click", function() {
|
||||
$(this).parent("div").children(".sct_sns_wrap").show();
|
||||
});
|
||||
$('.sct_sns_bg, .sct_sns_cls').click(function(){
|
||||
$('.sct_sns_wrap').hide();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@ -2,12 +2,20 @@
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품진열 20 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($this->list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$this->list_mod == 0) $sct_last = ' sct_last'; // 줄 마지막
|
||||
else if ($i%$this->list_mod == 1) $sct_last = ' sct_clear'; // 줄 첫번째
|
||||
@ -24,10 +32,10 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
}
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\" style=\"width:{$this->img_width}px\">\n";
|
||||
echo "<li class=\"sct_li{$sct_last}\" data-css=\"nocss\" style=\"width:{$this->img_width}px\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_img\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -47,7 +55,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -67,7 +75,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
@ -79,7 +87,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
@ -91,8 +99,8 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 20 끝 -->
|
||||
@ -2,13 +2,20 @@
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품진열 30 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$href = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$list_mod == 0) $sct_last = ' sct_last'; // 줄 마지막
|
||||
else if ($i%$list_mod == 1) $sct_last = ' sct_clear'; // 줄 첫번째
|
||||
@ -33,10 +40,10 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$list_width = $list_real_width - $list_right_pad - $list_left_pad;
|
||||
$list_height = $this->img_height - $list_top_pad - $list_bottom_pad;
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\" style=\"padding:{$list_top_pad}px {$list_right_pad}px {$list_bottom_pad}px {$list_left_pad}px;width:{$list_width}px;height:{$list_height}px\">\n";
|
||||
echo "<li class=\"sct_li{$sct_last}\" data-css=\"nocss\" style=\"padding:{$list_top_pad}px {$list_right_pad}px {$list_bottom_pad}px {$list_left_pad}px;width:{$list_width}px;height:{$list_height}px\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_img\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -56,7 +63,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -76,7 +83,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
@ -88,7 +95,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
@ -103,8 +110,8 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 12 끝 -->
|
||||
@ -2,15 +2,22 @@
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
// 관련상품 스킨은 사품을 한줄에 하나만 표시하며 해당 상품에 관련상품이 등록되어 있는 경우 기본으로 7개까지 노출합니다.
|
||||
?>
|
||||
|
||||
<!-- 상품진열 40 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$href = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$list_mod == 0) $sct_last = ' sct_last'; // 줄 마지막
|
||||
else if ($i%$list_mod == 1) $sct_last = ' sct_clear'; // 줄 첫번째
|
||||
@ -27,18 +34,18 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
}
|
||||
|
||||
$list_top_pad = 20;
|
||||
$list_right_pad = 10;
|
||||
$list_bottom_pad = 20;
|
||||
$list_left_pad = $this->img_width + 10;
|
||||
//$list_top_pad = 20;
|
||||
//$list_right_pad = 10;
|
||||
//$list_bottom_pad = 20;
|
||||
//$list_left_pad = $this->img_width + 10;
|
||||
//$list_real_width = 740;
|
||||
//$list_width = $list_real_width - $list_right_pad - $list_left_pad;
|
||||
$list_height = $this->img_height - $list_top_pad - $list_bottom_pad;
|
||||
//$list_height = $this->img_height - $list_top_pad - $list_bottom_pad;
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\" style=\"padding:{$list_top_pad}px {$list_right_pad}px {$list_bottom_pad}px {$list_left_pad}px;width:{$list_width}px;height:{$list_height}px\">\n";
|
||||
echo "<li class=\"sct_li{$sct_last}\" data-css=\"nocss\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_img\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -58,7 +65,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -78,7 +85,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
@ -88,16 +95,32 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</div>\n";
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
|
||||
echo "<div class=\"\">
|
||||
<button type=\"button\" class=\"\" data-it_id=\"{$row['it_id']}\"><i class=\"fa fa-shopping-cart\" aria-hidden=\"true\"></i> 장바구니</button>\n";
|
||||
echo "</div>\n";
|
||||
|
||||
// 위시리스트 + 공유 버튼 시작
|
||||
echo "<div class=\"sct_op_btn\">\n";
|
||||
echo "<button type=\"button\" class=\"btn_wish\" data-it_id=\"{$row['it_id']}\"><span class=\"sound_only\">위시리스트</span><i class=\"fa fa-heart-o\" aria-hidden=\"true\"></i></button>\n";
|
||||
echo "<button type=\"button\" class=\"btn_share\"><span class=\"sound_only\">공유하기</span><i class=\"fa fa-share-alt\" aria-hidden=\"true\"></i></button>\n";
|
||||
|
||||
echo "<div class=\"sct_sns_wrap\">";
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_twt_s.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_goo_s.png');
|
||||
echo "<h3>SNS 공유</h3>";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "<button type=\"button\" class=\"sct_sns_cls\"><span class=\"sound_only\">닫기</span><i class=\"fa fa-times\" aria-hidden=\"true\"></i></button>";
|
||||
echo "</div>\n";
|
||||
}
|
||||
echo "<div class=\"sct_sns_bg\"></div>";
|
||||
echo "</div></div>\n";
|
||||
// 위시리스트 + 공유 버튼 끝
|
||||
|
||||
// 관련상품
|
||||
echo "<div class=\"sct_rel\">".relation_item($row['it_id'], 70, 0, 5)."</div>\n";
|
||||
@ -105,8 +128,8 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열13 끝 -->
|
||||
|
||||
@ -2,10 +2,12 @@
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
$sct_sort_href = $_SERVER['SCRIPT_NAME'].'?';
|
||||
|
||||
if($ca_id)
|
||||
$sct_sort_href .= 'ca_id='.$ca_id;
|
||||
$sct_sort_href = shop_category_url($ca_id).'?1=1';
|
||||
else if($ev_id)
|
||||
$sct_sort_href .= 'ev_id='.$ev_id;
|
||||
|
||||
if($skin)
|
||||
$sct_sort_href .= '&skin='.$skin;
|
||||
$sct_sort_href .= '&sort=';
|
||||
@ -18,16 +20,16 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0
|
||||
<section id="sct_sort">
|
||||
<h2>상품 정렬</h2>
|
||||
|
||||
<!-- <ul>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_price&sortodr=asc">낮은가격순</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_price&sortodr=desc">높은가격순</a></li>
|
||||
<!-- 기타 정렬 옵션
|
||||
<ul>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_name&sortodr=asc">상품명순</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_type1&sortodr=desc">히트상품</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_type2&sortodr=desc">추천상품</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_type3&sortodr=desc">최신상품</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_type4&sortodr=desc">인기상품</a></li>
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_type5&sortodr=desc">할인상품</a></li>
|
||||
</ul> -->
|
||||
</ul>
|
||||
-->
|
||||
|
||||
<ul id="ssch_sort">
|
||||
<li><a href="<?php echo $sct_sort_href; ?>it_sum_qty&sortodr=desc">판매많은순</a></li>
|
||||
|
||||
@ -2,10 +2,11 @@
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<?php if(isset($ca['ca_skin']) && $ca['ca_skin'] === 'list.10.skin.php'){ ?>
|
||||
<ul id="sct_lst">
|
||||
<li><button type="button" class="sct_lst_view sct_lst_list"><i class="fa fa-th-list" aria-hidden="true"></i><span class="sound_only">리스트뷰</span></button></li>
|
||||
<li><button type="button" class="sct_lst_view sct_lst_gallery"><i class="fa fa-th-large" aria-hidden="true"></i><span class="sound_only">갤러리뷰</span></button></li>
|
||||
</ul>
|
||||
</ul>
|
||||
<?php } ?>
|
||||
@ -14,14 +14,14 @@ while ($row=sql_fetch_array($result)) {
|
||||
|
||||
$row2 = sql_fetch(" select count(*) as cnt from {$g5['g5_shop_item_table']} where (ca_id like '{$row['ca_id']}%' or ca_id2 like '{$row['ca_id']}%' or ca_id3 like '{$row['ca_id']}%') and it_use = '1' ");
|
||||
|
||||
$str .= '<li><a href="./list.php?ca_id='.$row['ca_id'].'">'.$row['ca_name'].' ('.$row2['cnt'].')</a></li>';
|
||||
$str .= '<li><a href="'.shop_category_url($row['ca_id']).'">'.$row['ca_name'].' ('.$row2['cnt'].')</a></li>';
|
||||
$exists = true;
|
||||
}
|
||||
|
||||
if ($exists) {
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품분류 1 시작 { -->
|
||||
|
||||
@ -31,27 +31,25 @@ if (!$exists) {
|
||||
|
||||
$str .= '<li>';
|
||||
if ($cnt) {
|
||||
$str .= '<a href="./list.php?ca_id='.$row['ca_id'].'" class="sct_ct_parent '.$sct_ct_here.'">'.$row['ca_name'].'</a>';
|
||||
$str .= '<a href="'.shop_category_url($row['ca_id']).'" class="sct_ct_parent '.$sct_ct_here.'">'.$row['ca_name'].'</a>';
|
||||
$sql2 = " select ca_id, ca_name from {$g5['g5_shop_category_table']} where ca_id like '{$row['ca_id']}%' and ca_use = '1' and length(ca_id) = $len4 order by ca_order, ca_id ";
|
||||
$result2 = sql_query($sql2);
|
||||
$k=0;
|
||||
while ($row2=sql_fetch_array($result2)) {
|
||||
$str .= '<a href="./list.php?ca_id='.$row2['ca_id'].'">'.$row2['ca_name'].'</a>';
|
||||
$str .= '<a href="'.shop_category_url($row2['ca_id']).'">'.$row2['ca_name'].'</a>';
|
||||
$k++;
|
||||
}
|
||||
} else {
|
||||
$str .= '<a href="./list.php?ca_id='.$row['ca_id'].'" class="sct_ct_parent '.$sct_ct_here.'">'.$row['ca_name'].'</a>';
|
||||
$str .= '<a href="'.shop_category_url($row['ca_id']).'" class="sct_ct_parent '.$sct_ct_here.'">'.$row['ca_name'].'</a>';
|
||||
}
|
||||
$str .= '</li>';
|
||||
$exists = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ($exists) {
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품분류 2 시작 { -->
|
||||
|
||||
@ -13,14 +13,14 @@ while ($row=sql_fetch_array($result)) {
|
||||
$sct_ct_here = 'sct_ct_here';
|
||||
else
|
||||
$sct_ct_here = '';
|
||||
$str .= '<li><a href="./list.php?ca_id='.$row['ca_id'].'" class="'.$sct_ct_here.'">'.$row['ca_name'].'</a></li>';
|
||||
$str .= '<li><a href="'.shop_category_url($row['ca_id']).'" class="'.$sct_ct_here.'">'.$row['ca_name'].'</a></li>';
|
||||
$exists = true;
|
||||
}
|
||||
|
||||
if ($exists) {
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품분류 3 시작 { -->
|
||||
|
||||
@ -7,7 +7,15 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
<!-- 상품진열 10 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($this->list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$this->list_mod == 0) $sct_last = 'sct_last'; // 줄 마지막
|
||||
else if ($i%$this->list_mod == 1) $sct_last = 'sct_clear'; // 줄 첫번째
|
||||
@ -15,12 +23,12 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
} else { // 1줄 이미지 : 1개
|
||||
$sct_last = 'sct_clear';
|
||||
}
|
||||
|
||||
|
||||
if ($i == 1) {
|
||||
if ($this->css) {
|
||||
echo "<ul class=\"{$this->css}\">\n";
|
||||
} else {
|
||||
echo "<ul class=\"sct sct_10\">\n";
|
||||
echo "<ul class=\"sct smt_40 owl-carousel\">\n";
|
||||
}
|
||||
}
|
||||
|
||||
@ -29,7 +37,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<div class=\"sct_img\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -40,26 +48,19 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</a>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
|
||||
// 사용후기 평점표시
|
||||
if ($this->view_star && $star_score) {
|
||||
echo "<div class=\"sct_star\"><span class=\"sound_only\">고객평점</span><img src=\"".G5_SHOP_URL."/img/s_star".$star_score.".png\" alt=\"별점 ".$star_score."점\" class=\"sit_star\"></div>\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -70,18 +71,10 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
echo "<div class=\"sct_basic\">".stripslashes($row['it_basic'])."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<span class=\"sct_discount\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
@ -90,17 +83,11 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 10 끝 -->
|
||||
@ -19,8 +19,16 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">',
|
||||
|
||||
<!-- 상품진열 20 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$sct_last = '';
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if($i>1 && $i%$this->list_mod == 0)
|
||||
$sct_last = ' sct_last'; // 줄 마지막
|
||||
|
||||
@ -38,10 +46,10 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<ul class=\"sct_ul\">\n";
|
||||
}
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\" style=\"width:{$this->img_width}px\">";
|
||||
echo "<li class=\"sct_li{$sct_last}\">";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_img\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -52,16 +60,12 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\" class=\"sct_a\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -81,7 +85,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
@ -94,24 +98,28 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\" style=\"top:{$sns_top}px\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_twt_s.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_goo_s.png');
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) {
|
||||
if ($i >= 1) {
|
||||
echo "</ul>\n";
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
|
||||
<script>
|
||||
|
||||
@ -4,40 +4,43 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
/*
|
||||
상품리스트가 일정 시간마다 좌로 롤링되는 스킨
|
||||
롤링되기 위해서는 상품이 2줄 이상이어야 함
|
||||
*/
|
||||
// 관련상품 스킨은 사품을 한줄에 하나만 표시하며 해당 상품에 관련상품이 등록되어 있는 경우 기본으로 7개까지 노출합니다.
|
||||
add_javascript('<script src="'.G5_THEME_JS_URL.'/theme.shop.list.js"></script>', 10);
|
||||
?>
|
||||
|
||||
<!-- 이전 재생 정지 다음 버튼 시작 { -->
|
||||
<ul id="btn_smt_<?php echo $this->type; ?>" class="sctrl">
|
||||
<li><button type="button" class="sctrl_play">효과재생<span></span></button></li>
|
||||
<li><button type="button" class="sctrl_stop">효과정지<span></span></button></li>
|
||||
</ul>
|
||||
<!-- } 이전 재생 정지 다음 버튼 끝 -->
|
||||
|
||||
<!-- 상품유형 30 시작 { -->
|
||||
<!-- 상품진열 30 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$list_mod == 0) $sct_last = ' sct_last'; // 줄 마지막
|
||||
else if ($i%$list_mod == 1) $sct_last = ' sct_clear'; // 줄 첫번째
|
||||
else $sct_last = '';
|
||||
} else { // 1줄 이미지 : 1개
|
||||
$sct_last = ' sct_clear';
|
||||
}
|
||||
|
||||
if ($i == 1) {
|
||||
if ($this->css) {
|
||||
echo "<div id=\"smt_{$this->type}\" class=\"{$this->css}\">\n";
|
||||
echo "<ul class=\"{$this->css}\">\n";
|
||||
} else {
|
||||
echo "<div id=\"smt_{$this->type}\" class=\"smt_30\">\n";
|
||||
echo "<ul class=\"smt smt_10\">\n";
|
||||
}
|
||||
echo "<ul class=\"sct_ul sct_ul_first\">\n";
|
||||
}
|
||||
}
|
||||
|
||||
if ($i>1 && $i%$this->list_mod == 1) {
|
||||
echo "</ul>";
|
||||
echo "<ul class=\"sct_ul\">";
|
||||
}
|
||||
echo "<li class=\"sct_li{$sct_last}\">\n";
|
||||
|
||||
echo "<li class=\"sct_li\" style=\"width:{$this->img_width}px\">\n";
|
||||
echo "<div class=\"sct_img\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -45,19 +48,38 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
echo "</a>\n";
|
||||
}
|
||||
|
||||
// 할인율 표시 ( 전화문의가 아니며 판매가격 과 시중가격 이 있을때 표시 (A-B)/A*100 )
|
||||
if ($row['it_cust_price'] && $row['it_price'] && !$row['it_tel_inq']) {
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
$sale_per = round( (get_price($row)/$row['it_cust_price']) * 100 , 1).'%';
|
||||
|
||||
echo '<span class="sct_disc">'.$sale_per.'</span>'.PHP_EOL;
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
// 품절
|
||||
if (is_soldout($row['it_id'], true)) {
|
||||
echo '<span class="shop_icon_soldout"><span class="soldout_txt">SOLD OUT</span></span>';
|
||||
}
|
||||
}
|
||||
echo "</div>\n";
|
||||
|
||||
echo "<div class=\"sct_ct_wrap\">\n";
|
||||
|
||||
// 사용후기 평점표시
|
||||
if ($this->view_star && $star_score) {
|
||||
echo "<div class=\"sct_star\"><span class=\"sound_only\">고객평점</span><img src=\"".G5_SHOP_URL."/img/s_star".$star_score.".png\" alt=\"별점 ".$star_score."점\" class=\"sit_star\"></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\" class=\"sct_a\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -67,195 +89,72 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
echo "<div class=\"sct_basic\">".stripslashes($row['it_basic'])."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_sns) {
|
||||
|
||||
|
||||
// 위시리스트 + 공유 버튼 시작 {
|
||||
echo "<div class=\"sct_op_btn\">\n";
|
||||
echo "<button type=\"button\" class=\"btn_wish\" data-it_id=\"{$row['it_id']}\"><span class=\"sound_only\">위시리스트</span><i class=\"fa fa-heart-o\" aria-hidden=\"true\"></i></button>\n";
|
||||
echo "<button type=\"button\" class=\"btn_share\"><span class=\"sound_only\">공유하기</span><i class=\"fa fa-share-alt\" aria-hidden=\"true\"></i></button>\n";
|
||||
|
||||
echo "<div class=\"sct_sns_wrap\">";
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\" style=\"top:{$sns_top}px\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_twt_s.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_goo_s.png');
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo "<h3>SNS 공유</h3>";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "<button type=\"button\" class=\"sct_sns_cls\"><span class=\"sound_only\">닫기</span><i class=\"fa fa-times\" aria-hidden=\"true\"></i></button>";
|
||||
echo "</div>\n";
|
||||
}
|
||||
echo "<div class=\"sct_sns_bg\"></div>";
|
||||
echo "</div></div>\n";
|
||||
// } 위시리스트 + 공유 버튼 끝
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sit_icon_li\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) {
|
||||
echo "</ul>\n";
|
||||
echo "</div>\n";
|
||||
}
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 30 끝 -->
|
||||
|
||||
<script>
|
||||
(function($) {
|
||||
var intervals = {};
|
||||
|
||||
var methods = {
|
||||
init: function(option)
|
||||
{
|
||||
if(this.length < 1)
|
||||
return false;
|
||||
|
||||
var $smt = this.find("ul.sct_ul");
|
||||
var $smt_a = $smt.find("a");
|
||||
var width = $smt.eq(0).width();
|
||||
var height = 0;
|
||||
var count = $smt.size();
|
||||
var c_idx = smt_o_idx = 0;
|
||||
var fx = null;
|
||||
var el_id = this[0].id;
|
||||
|
||||
$smt.each(function() {
|
||||
var h = $(this).outerHeight(true);
|
||||
if(h > height)
|
||||
height = h;
|
||||
});
|
||||
|
||||
this.height(height);
|
||||
|
||||
// 기본 설정값
|
||||
var settings = $.extend({
|
||||
interval: 6000,
|
||||
duration: 1500
|
||||
}, option);
|
||||
|
||||
if(count < 2)
|
||||
return;
|
||||
|
||||
set_interval();
|
||||
|
||||
$smt.hover(
|
||||
function() {
|
||||
clear_interval();
|
||||
},
|
||||
function() {
|
||||
set_interval();
|
||||
}
|
||||
);
|
||||
|
||||
$smt_a.on("focusin", function() {
|
||||
clear_interval();
|
||||
});
|
||||
|
||||
$smt_a.on("focusout", function() {
|
||||
set_interval();
|
||||
});
|
||||
|
||||
function left_rolling() {
|
||||
$smt.each(function(index) {
|
||||
if($(this).is(":visible")) {
|
||||
o_idx = index;
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
$smt.eq(o_idx).animate(
|
||||
{ left: "-="+width+"px" }, settings.duration,
|
||||
function() {
|
||||
$(this).css("display", "none").css("left", width+"px");
|
||||
}
|
||||
);
|
||||
|
||||
c_idx = (o_idx + 1) % count;
|
||||
|
||||
$smt.eq(c_idx).css("display", "block").animate(
|
||||
{ left: "-="+width+"px" }, settings.duration,
|
||||
function() {
|
||||
o_idx = c_idx;
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
function set_interval() {
|
||||
if(count > 1) {
|
||||
clear_interval();
|
||||
|
||||
if($("#btn_"+el_id).find("button.sctrl_stop").data("stop") == true)
|
||||
return;
|
||||
|
||||
intervals[el_id] = setInterval(left_rolling, settings.interval);
|
||||
|
||||
// control 버튼 class
|
||||
$("#btn_"+el_id).find("button span").removeClass("sctrl_on").html("")
|
||||
.end().find("button.sctrl_play span").addClass("sctrl_on").html("<b class=\"sound_only\">선택됨</b>");
|
||||
}
|
||||
}
|
||||
|
||||
function clear_interval() {
|
||||
if(intervals[el_id]) {
|
||||
clearInterval(intervals[el_id]);
|
||||
|
||||
// control 버튼 class
|
||||
$("#btn_"+el_id).find("button span").removeClass("sctrl_on").html("")
|
||||
.end().find("button.sctrl_stop span").addClass("sctrl_on").html("<b class=\"sound_only\">선택됨</b>");
|
||||
}
|
||||
}
|
||||
},
|
||||
stop: function()
|
||||
{
|
||||
var el_id = this[0].id;
|
||||
if(intervals[el_id])
|
||||
clearInterval(intervals[el_id]);
|
||||
}
|
||||
};
|
||||
|
||||
$.fn.leftRolling = function(option) {
|
||||
if (methods[option])
|
||||
return methods[option].apply(this, Array.prototype.slice.call(arguments, 1));
|
||||
else
|
||||
return methods.init.apply(this, arguments);
|
||||
}
|
||||
}(jQuery));
|
||||
|
||||
$(function() {
|
||||
$("#smt_<?php echo $this->type; ?>").leftRolling();
|
||||
// 기본 설정값을 변경하려면 아래처럼 사용
|
||||
//$("#smt_<?php echo $this->type; ?>").leftRolling({ interval: 6000, duration: 1500 });
|
||||
|
||||
// 애니메이션 play
|
||||
$("#btn_smt_<?php echo $this->type; ?> button.sctrl_play").on("click", function() {
|
||||
$("#btn_smt_<?php echo $this->type; ?> button.sctrl_stop").data("stop", false);
|
||||
|
||||
var id = $(this).closest(".sctrl").attr("id").replace("btn_", "");
|
||||
$("#"+id).leftRolling();
|
||||
//$("#"+id).leftRolling({ interval: 6000, duration: 1500 });
|
||||
});
|
||||
|
||||
// 애니메이션 stop
|
||||
$("#btn_smt_<?php echo $this->type; ?> button.sctrl_stop").on("click", function() {
|
||||
if($(this).parent().siblings().find(".sctrl_on").size() > 0) {
|
||||
$(this).parent().siblings().find("span").removeClass("sctrl_on").html("");
|
||||
$(this).children().addClass("sctrl_on").html("<b class=\"sound_only\">선택됨</b>");
|
||||
var id = $(this).closest(".sctrl").attr("id").replace("btn_", "");
|
||||
$("#"+id).leftRolling("stop");
|
||||
|
||||
$(this).data("stop", true);
|
||||
}
|
||||
});
|
||||
});
|
||||
//SNS 공유
|
||||
$(function (){
|
||||
$(".btn_share").on("click", function() {
|
||||
$(this).parent("div").children(".sct_sns_wrap").show();
|
||||
});
|
||||
$('.sct_sns_bg, .sct_sns_cls').click(function(){
|
||||
$('.sct_sns_wrap').hide();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<!-- } 상품진열 30 끝 -->
|
||||
|
||||
|
||||
@ -5,12 +5,20 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
|
||||
// 관련상품 스킨은 사품을 한줄에 하나만 표시하며 해당 상품에 관련상품이 등록되어 있는 경우 기본으로 7개까지 노출합니다.
|
||||
add_javascript('<script src="'.G5_THEME_JS_URL.'/theme.shop.list.js"></script>', 10);
|
||||
?>
|
||||
|
||||
<!-- 상품진열 40 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
$href = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
if ($list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$list_mod == 0) $sct_last = ' sct_last'; // 줄 마지막
|
||||
else if ($i%$list_mod == 1) $sct_last = ' sct_clear'; // 줄 첫번째
|
||||
@ -23,23 +31,16 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->css) {
|
||||
echo "<ul class=\"{$this->css}\">\n";
|
||||
} else {
|
||||
echo "<ul class=\"smt smt_40\">\n";
|
||||
echo "<ul class=\"smt smt_10\">\n";
|
||||
}
|
||||
}
|
||||
|
||||
$list_top_pad = 20;
|
||||
$list_right_pad = 20;
|
||||
$list_bottom_pad = 20;
|
||||
$list_left_pad = $this->img_width + 20;
|
||||
$list_height = $this->img_height + 2;
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\" style=\"padding:{$list_top_pad}px {$list_right_pad}px {$list_bottom_pad}px {$list_left_pad}px;width:{$list_width}px;height:{$list_height}px\">\n";
|
||||
|
||||
echo "<li class=\"sct_li{$sct_last}\">\n";
|
||||
|
||||
echo "<div class=\"sct_img\">\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
@ -50,26 +51,33 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
echo "</a>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "</div>\n";
|
||||
echo "<div class=\"sct_btn\">
|
||||
<button type=\"button\" class=\"btn_cart sct_cart\" data-it_id=\"{$row['it_id']}\"><i class=\"fa fa-shopping-cart\" aria-hidden=\"true\"></i> 장바구니</button>\n";
|
||||
echo "</div>\n";
|
||||
|
||||
echo "<div class=\"cart-layer\"></div>\n";
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
// 품절
|
||||
if (is_soldout($row['it_id'], true)) {
|
||||
echo '<span class="shop_icon_soldout"><span class="soldout_txt">SOLD OUT</span></span>';
|
||||
}
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
echo "<div class=\"sct_ct_wrap\">\n";
|
||||
|
||||
// 사용후기 평점표시
|
||||
if ($this->view_star && $star_score) {
|
||||
echo "<div class=\"sct_star\"><span class=\"sound_only\">고객평점</span><img src=\"".G5_SHOP_URL."/img/s_star".$star_score.".png\" alt=\"별점 ".$star_score."점\" class=\"sit_star\"></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
@ -79,37 +87,66 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
echo "<div class=\"sct_basic\">".stripslashes($row['it_basic'])."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<span class=\"sct_discount\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
|
||||
|
||||
// 위시리스트 + 공유 버튼 시작 {
|
||||
echo "<div class=\"sct_op_btn\">\n";
|
||||
echo "<button type=\"button\" class=\"btn_wish\" data-it_id=\"{$row['it_id']}\"><span class=\"sound_only\">위시리스트</span><i class=\"fa fa-heart-o\" aria-hidden=\"true\"></i></button>\n";
|
||||
echo "<button type=\"button\" class=\"btn_share\"><span class=\"sound_only\">공유하기</span><i class=\"fa fa-share-alt\" aria-hidden=\"true\"></i></button>\n";
|
||||
|
||||
echo "<div class=\"sct_sns_wrap\">";
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = $item_link_href;
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\">";
|
||||
echo "<h3>SNS 공유</h3>";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/facebook.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/twitter.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/gplus.png');
|
||||
echo "<button type=\"button\" class=\"sct_sns_cls\"><span class=\"sound_only\">닫기</span><i class=\"fa fa-times\" aria-hidden=\"true\"></i></button>";
|
||||
echo "</div>\n";
|
||||
}
|
||||
echo "<div class=\"sct_sns_bg\"></div>";
|
||||
echo "</div></div>\n";
|
||||
// } 위시리스트 + 공유 버튼 끝
|
||||
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sit_icon_li\">".item_icon($row)."</div>\n";
|
||||
}
|
||||
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열13 끝 -->
|
||||
<!-- } 상품진열40 끝 -->
|
||||
|
||||
<script>
|
||||
//SNS 공유
|
||||
$(function (){
|
||||
$(".btn_share").on("click", function() {
|
||||
$(this).parent("div").children(".sct_sns_wrap").show();
|
||||
});
|
||||
$('.sct_sns_bg, .sct_sns_cls').click(function(){
|
||||
$('.sct_sns_wrap').hide();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@ -1,101 +1,83 @@
|
||||
<?php
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
?>
|
||||
|
||||
<!-- 상품진열 10 시작 { -->
|
||||
<!-- 상품진열 50 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
if ($i%$this->list_mod == 0) $sct_last = 'sct_last'; // 줄 마지막
|
||||
else if ($i%$this->list_mod == 1) $sct_last = 'sct_clear'; // 줄 첫번째
|
||||
else $sct_last = '';
|
||||
} else { // 1줄 이미지 : 1개
|
||||
$sct_last = 'sct_clear';
|
||||
}
|
||||
$i=0;
|
||||
foreach((array) $list as $row){
|
||||
|
||||
if( empty($row) ) continue;
|
||||
$i++;
|
||||
|
||||
$item_link_href = shop_item_url($row['it_id']);
|
||||
$star_score = $row['it_use_avg'] ? (int) get_star($row['it_use_avg']) : '';
|
||||
|
||||
$sct_last = '';
|
||||
if($i>1 && $i%$this->list_mod == 0)
|
||||
$sct_last = ' sct_last'; // 줄 마지막
|
||||
if ($i == 1) {
|
||||
if ($this->css) {
|
||||
echo "<ul class=\"{$this->css}\">\n";
|
||||
} else {
|
||||
echo "<ul id=\"smt_{$this->type}\" class=\" smt_50\">\n";
|
||||
echo "<ul id=\"smt_{$this->type}\" class=\"smt_30\">\n";
|
||||
}
|
||||
}
|
||||
|
||||
echo "<li class=\"sct_li sct_li_{$i}\">\n";
|
||||
|
||||
echo "<span class=\"sct_rank\">{$i}</span>\n";
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_img\"><a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<div class=\"sct_img\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_img) {
|
||||
echo get_it_image($row['it_id'], $this->img_width, $this->img_height, '', '', stripslashes($row['it_name']))."\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_icon) {
|
||||
echo "<div class=\"sct_icon\">".item_icon($row)."</div>\n";
|
||||
|
||||
|
||||
echo "<div class=\"sct_cnt\">\n";
|
||||
|
||||
// 사용후기 평점표시
|
||||
if ($this->view_star && $star_score) {
|
||||
echo "<span class=\"sound_only\">고객평점</span><img src=\"".G5_SHOP_URL."/img/s_star".$star_score.".png\" alt=\"별 ".$star_score."개\" class=\"sit_star\" width=\"100\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_id) {
|
||||
echo "<div class=\"sct_id\"><".stripslashes($row['it_id'])."></div>\n";
|
||||
}
|
||||
|
||||
|
||||
if ($this->href) {
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$this->href}{$row['it_id']}\">\n";
|
||||
echo "<div class=\"sct_txt\"><a href=\"{$item_link_href}\">\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_name) {
|
||||
echo stripslashes($row['it_name'])."\n";
|
||||
}
|
||||
|
||||
if ($this->href) {
|
||||
echo "</a></div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_basic && $row['it_basic']) {
|
||||
echo "<div class=\"sct_basic\">".stripslashes($row['it_basic'])."</div>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_cust_price || $this->view_it_price) {
|
||||
|
||||
echo "<div class=\"sct_cost\">\n";
|
||||
|
||||
if ($this->view_it_cust_price && $row['it_cust_price']) {
|
||||
echo "<strike>".display_price($row['it_cust_price'])."</strike>\n";
|
||||
echo "<span class=\"sct_dict\">".display_price($row['it_cust_price'])."</span>\n";
|
||||
}
|
||||
|
||||
if ($this->view_it_price) {
|
||||
echo display_price(get_price($row), $row['it_tel_inq'])."\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
|
||||
}
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\" style=\"top:{$sns_top}px\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
echo get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_twt_s.png');
|
||||
echo get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_goo_s.png');
|
||||
echo "</div>\n";
|
||||
}
|
||||
|
||||
echo "</div>\n";
|
||||
echo "</li>\n";
|
||||
}
|
||||
|
||||
if ($i > 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
if ($i >= 1) echo "</ul>\n";
|
||||
if($i == 0) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 10 끝 -->
|
||||
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$('.smt_30').bxSlider({
|
||||
minSlides: 4,
|
||||
maxSlides: 4,
|
||||
mode: 'vertical',
|
||||
pager:false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<!-- } 상품진열 50 끝 -->
|
||||
@ -3,29 +3,27 @@ if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
add_javascript('<script src="'.G5_JS_URL.'/jquery.bxslider.js"></script>', 10);
|
||||
?>
|
||||
add_javascript('<script src="'.G5_JS_URL.'/owlcarousel/owl.carousel.min.js"></script>', 10);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_JS_URL.'/owlcarousel/owl.carousel.min.css">', 10);
|
||||
|
||||
<?php
|
||||
$max_width = $max_height = 0;
|
||||
$bn_first_class = ' class="bn_first"';
|
||||
$bn_slide_btn = '';
|
||||
$bn_sl = ' class="bn_sl"';
|
||||
|
||||
$main_banners = array();
|
||||
|
||||
for ($i=0; $row=sql_fetch_array($result); $i++)
|
||||
{
|
||||
$main_banners[] = $row;
|
||||
|
||||
if ($i==0) echo '<div id="main_bn">'.PHP_EOL.'<ul class="slide-wrap">'.PHP_EOL;
|
||||
//print_r2($row);
|
||||
// 테두리 있는지
|
||||
$bn_border = ($row['bn_border']) ? ' class="sbn_border"' : '';;
|
||||
// 새창 띄우기인지
|
||||
$bn_new_win = ($row['bn_new_win']) ? ' target="_blank"' : '';
|
||||
|
||||
$bimg = G5_DATA_PATH.'/banner/'.$row['bn_id'];
|
||||
$item_html = '';
|
||||
|
||||
if (file_exists($bimg))
|
||||
{
|
||||
$banner = '';
|
||||
@ -40,50 +38,107 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
|
||||
if($max_height < $size[1])
|
||||
$max_height = $size[1];
|
||||
|
||||
echo '<li'.$bn_first_class.'>'.PHP_EOL;
|
||||
$item_html .= '<div class="item">';
|
||||
if ($row['bn_url'][0] == '#')
|
||||
$banner .= '<a href="'.$row['bn_url'].'">';
|
||||
else if ($row['bn_url'] && $row['bn_url'] != 'http://') {
|
||||
$banner .= '<a href="'.G5_SHOP_URL.'/bannerhit.php?bn_id='.$row['bn_id'].'"'.$bn_new_win.'>';
|
||||
}
|
||||
echo $banner.'<img src="'.G5_DATA_URL.'/banner/'.$row['bn_id'].'" width="'.$size[0].'" alt="'.get_text($row['bn_alt']).'"'.$bn_border.'>';
|
||||
$item_html .= $banner.'<img src="'.G5_DATA_URL.'/banner/'.$row['bn_id'].'" width="'.$size[0].'" alt="'.get_text($row['bn_alt']).'"'.$bn_border.'>';
|
||||
if($banner)
|
||||
echo '</a>'.PHP_EOL;
|
||||
echo '</li>'.PHP_EOL;
|
||||
|
||||
|
||||
$item_html .= '</a>';
|
||||
$item_html .= '</div>';
|
||||
}
|
||||
|
||||
$banner_style = $max_height ? 'style="min-height:'.($max_height + 25).'px"' : '';
|
||||
if ($i==0) echo '<div id="main_bn"><div class="main_image_area"><div class="main_banner_owl owl-carousel">'.PHP_EOL;
|
||||
|
||||
echo $item_html;
|
||||
}
|
||||
|
||||
if ($i > 0) {
|
||||
echo '</ul>'.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
|
||||
echo '<div class="btn_wr"><a href="#" class="pager-prev"><i class="fa fa-angle-left"></i></a><div id="slide-counter"></div><a href="#" class="pager-next"><i class="fa fa-angle-right"></i></a> </div>'.PHP_EOL;
|
||||
|
||||
echo '<div id="bx_pager" class="bx_pager">
|
||||
<ul>';
|
||||
echo '</div>'.PHP_EOL;
|
||||
|
||||
echo '<div class="main_owl_pager">'.PHP_EOL;
|
||||
echo '<div class="owl_pager">
|
||||
<ul class="carousel-custom-dots owl-dots">';
|
||||
$k = 0;
|
||||
foreach( $main_banners as $row ){
|
||||
echo '<li> <a data-slide-index="'.$k.'" href="">'.get_text($row['bn_alt']).'</a></li>'.PHP_EOL;
|
||||
$alt_title = $row['bn_alt'] ? cut_str(get_text($row['bn_alt']), 12, '') : ' ';
|
||||
echo '<li class="owl-dot"><a data-slide-index="'.$k.'" href="#">'.$alt_title.'</a></li>'.PHP_EOL;
|
||||
$k++;
|
||||
}
|
||||
}
|
||||
|
||||
echo '</ul>
|
||||
</div>'.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
echo '</div>'.PHP_EOL;
|
||||
?>
|
||||
|
||||
<script>
|
||||
jQuery(function($){
|
||||
var slider = $('.slide-wrap').show().bxSlider({
|
||||
speed:800,
|
||||
pagerCustom: '#bx_pager',
|
||||
auto: true,
|
||||
useCSS : false,
|
||||
onSlideAfter : function(){
|
||||
slider.startAuto();
|
||||
|
||||
function owl_show_page(event){
|
||||
|
||||
if (event.item) {
|
||||
var count = event.item.count,
|
||||
item_index = event.item.index,
|
||||
index = 1;
|
||||
|
||||
if( is_loop ){
|
||||
index = ( 1 + ( event.property.value - Math.ceil( event.item.count / 2 ) ) % event.item.count || 0 ) || 1;
|
||||
} else {
|
||||
index = event.item.index ? event.item.index + 1 : 1;
|
||||
}
|
||||
|
||||
$(event.target).next(".btn_wr").find(".slide-index").text(index);
|
||||
}
|
||||
}
|
||||
|
||||
var is_loop = true,
|
||||
item_totals = $('.main_banner_owl .item').length;
|
||||
|
||||
if( item_totals ){
|
||||
$('#slide-counter').prepend('<strong class="slide-index current-index"></strong> / ')
|
||||
.append('<span class="total-slides">'+item_totals+'</span>');
|
||||
}
|
||||
|
||||
var owl = $('.main_banner_owl').owlCarousel({
|
||||
items:1,
|
||||
loop:is_loop,
|
||||
margin:0,
|
||||
nav:false,
|
||||
autoHeight:true,
|
||||
autoplay:true,
|
||||
autoplayTimeout:5000, // 5000은 5초
|
||||
autoplayHoverPause:true,
|
||||
dotsContainer: '.carousel-custom-dots',
|
||||
onChanged:function(event){
|
||||
owl_show_page(event);
|
||||
},
|
||||
});
|
||||
|
||||
// Custom Navigation Events
|
||||
$(document).on("click", ".carousel-custom-dots a", function(e){
|
||||
e.preventDefault();
|
||||
owl.trigger('to.owl.carousel', [$(this).parent().index(), 300]);
|
||||
});
|
||||
|
||||
$(document).on("click", ".btn_wr .pager-next", function(e){
|
||||
e.preventDefault();
|
||||
owl.trigger('next.owl.carousel');
|
||||
});
|
||||
|
||||
$(document).on("click", ".btn_wr .pager-prev", function(e){
|
||||
e.preventDefault();
|
||||
owl.trigger('prev.owl.carousel');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
@ -1,38 +1,83 @@
|
||||
<?php
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
if ($ca_id)
|
||||
{
|
||||
$navigation = $bar = "";
|
||||
$len = strlen($ca_id) / 2;
|
||||
for ($i=1; $i<=$len; $i++)
|
||||
{
|
||||
$code = substr($ca_id,0,$i*2);
|
||||
$navi_datas = $ca_ids = array();
|
||||
$is_item_view = (isset($it_id) && isset($it) && isset($it['it_id']) && $it_id === $it['it_id']) ? true : false;
|
||||
|
||||
$sql = " select ca_name from {$g5['g5_shop_category_table']} where ca_id = '$code' ";
|
||||
$row = sql_fetch($sql);
|
||||
|
||||
$sct_here = '';
|
||||
if ($ca_id == $code) // 현재 분류와 일치하면
|
||||
$sct_here = 'sct_here';
|
||||
|
||||
if ($i != $len) // 현재 위치의 마지막 단계가 아니라면
|
||||
$sct_bg = 'sct_bg';
|
||||
else $sct_bg = '';
|
||||
|
||||
$navigation .= $bar.'<a href="./list.php?ca_id='.$code.'" class="'.$sct_here.' '.$sct_bg.'">'.$row['ca_name'].'</a>';
|
||||
}
|
||||
if( !$is_item_view && $ca_id ){
|
||||
$navi_datas = get_shop_navigation_data(true, $ca_id);
|
||||
$ca_ids = array(
|
||||
'ca_id' => substr($ca_id,0,2),
|
||||
'ca_id2' => substr($ca_id,0,4),
|
||||
'ca_id3' => substr($ca_id,0,6),
|
||||
);
|
||||
} else if( $is_item_view && isset($it) && is_array($it) ) {
|
||||
$navi_datas = get_shop_navigation_data(true, $it['ca_id']);
|
||||
$ca_ids = array(
|
||||
'ca_id' => substr($it['ca_id'],0,2),
|
||||
'ca_id2' => substr($it['ca_id'],0,4),
|
||||
'ca_id3' => substr($it['ca_id'],0,6)
|
||||
);
|
||||
}
|
||||
else
|
||||
$navigation = $g5['title'];
|
||||
|
||||
//if ($it_id) $navigation .= " > $it[it_name]";
|
||||
$location_class = array();
|
||||
if($is_item_view){
|
||||
$location_class[] = 'view_location'; // view_location는 리스트 말고 상품보기에서만 표시
|
||||
} else {
|
||||
$location_class[] = 'is_list is_right'; // view_location는 리스트 말고 상품보기에서만 표시
|
||||
}
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_javascript('<script src="'.G5_JS_URL.'/shop.category.navigation.js"></script>', 10);
|
||||
?>
|
||||
|
||||
<div id="sct_location">
|
||||
<a href='<?php echo G5_SHOP_URL; ?>/' class="sct_bg">HOME</a>
|
||||
<?php echo $navigation; ?>
|
||||
<div id="sct_location" class="<?php echo implode(' ', $location_class);?>"> <!-- class="view_location" --> <!-- view_location는 리스트 말고 상품보기에서만 표시 -->
|
||||
<a href='<?php echo G5_SHOP_URL; ?>/' class="go_home"><span class="sound_only">메인으로</span><i class="fa fa-home" aria-hidden="true"></i></a>
|
||||
<i class="dividing-line fa fa-angle-right" aria-hidden="true"></i>
|
||||
<?php if ( is_array($navi_datas) && $navi_datas ){ ?>
|
||||
|
||||
<?php if( isset($navi_datas[0]) && $navi_datas[0] ){ ?>
|
||||
<select class="shop_hover_selectbox category1">
|
||||
<?php foreach((array) $navi_datas[0] as $data ){ ?>
|
||||
<option value="<?php echo $data['ca_id']; ?>" data-url="<?php echo $data['url']; ?>" <?php if($ca_ids['ca_id'] === $data['ca_id']) echo 'selected'; ?>><?php echo $data['ca_name']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } ?>
|
||||
<?php if( isset($navi_datas[1]) && $navi_datas[1] ){ ?>
|
||||
<i class="dividing-line fa fa-angle-right" aria-hidden="true"></i>
|
||||
<select class="shop_hover_selectbox category2">
|
||||
<?php foreach((array) $navi_datas[1] as $data ){ ?>
|
||||
<option value="<?php echo $data['ca_id']; ?>" data-url="<?php echo $data['url']; ?>" <?php if($ca_ids['ca_id2'] === $data['ca_id']) echo 'selected'; ?>><?php echo $data['ca_name']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } ?>
|
||||
<?php if( isset($navi_datas[2]) && $navi_datas[2] ){ ?>
|
||||
<i class="dividing-line fa fa-angle-right" aria-hidden="true"></i>
|
||||
<select class="shop_hover_selectbox category3">
|
||||
<?php foreach((array) $navi_datas[2] as $data ){ ?>
|
||||
<option value="<?php echo $data['ca_id']; ?>" data-url="<?php echo $data['url']; ?>" <?php if($ca_ids['ca_id3'] === $data['ca_id']) echo 'selected'; ?>><?php echo $data['ca_name']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } ?>
|
||||
<?php } else { ?>
|
||||
<?php echo get_text($g5['title']); ?>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<script>
|
||||
jQuery(function($){
|
||||
$(document).ready(function() {
|
||||
$("#sct_location select").on("change", function(e){
|
||||
var url = $(this).find(':selected').attr("data-url");
|
||||
|
||||
if (typeof itemlist_ca_id != "undefined" && itemlist_ca_id === this.value) {
|
||||
return false;
|
||||
}
|
||||
|
||||
window.location.href = url;
|
||||
});
|
||||
|
||||
$("select.shop_hover_selectbox").shop_select_to_html();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@ -2,10 +2,11 @@
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
|
||||
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_CSS_URL.'/style.css">', 0);
|
||||
add_stylesheet('<link rel="stylesheet" href="'.G5_SHOP_SKIN_URL.'/style.css">', 0);
|
||||
add_javascript('<script src="'.G5_JS_URL.'/jquery.bxslider.js"></script>', 10);
|
||||
?>
|
||||
<!-- 상품진열 10 시작 { -->
|
||||
|
||||
<!-- 관련상품 10 시작 { -->
|
||||
<?php
|
||||
for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
if ($this->list_mod >= 2) { // 1줄 이미지 : 2개 이상
|
||||
@ -76,7 +77,7 @@ for ($i=1; $row=sql_fetch_array($result); $i++) {
|
||||
|
||||
if ($this->view_sns) {
|
||||
$sns_top = $this->img_height + 10;
|
||||
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$row['it_id'];
|
||||
$sns_url = shop_item_url($row['it_id']);
|
||||
$sns_title = get_text($row['it_name']).' | '.get_text($config['cf_title']);
|
||||
echo "<div class=\"sct_sns\" style=\"top:{$sns_top}px\">";
|
||||
echo get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_SKIN_URL.'/img/sns_fb_s.png');
|
||||
@ -92,14 +93,14 @@ if ($i > 1) echo "</ul>\n";
|
||||
|
||||
if($i == 1) echo "<p class=\"sct_noitem\">등록된 상품이 없습니다.</p>\n";
|
||||
?>
|
||||
<!-- } 상품진열 10 끝 -->
|
||||
<!-- } 관련상품 10 끝 -->
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$('.scr_10').bxSlider({
|
||||
slideWidth: 160,
|
||||
minSlides: 5,
|
||||
maxSlides: 5,
|
||||
slideMargin: 20,
|
||||
slideWidth:175,
|
||||
minSlides:6,
|
||||
maxSlides:6,
|
||||
slideMargin:20,
|
||||
pager:false
|
||||
});
|
||||
});
|
||||
|
||||
@ -2,68 +2,60 @@
|
||||
if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
?>
|
||||
<?php if ($is_admin) { //관리자이면 ?>
|
||||
<div class="sit_admin"><a href="<?php echo G5_ADMIN_URL; ?>/shop_admin/configform.php#anc_scf_etc" class="btn_admin">검색 설정</a></div>
|
||||
<div class="sit_admin"><a href="<?php echo G5_ADMIN_URL; ?>/shop_admin/configform.php#anc_scf_etc" class="btn_admin btn"><i class="fa fa-cog fa-spin fa-fw"></i><span class="sound_only">검색 설정</span></a></div>
|
||||
<?php } ?>
|
||||
<!-- 검색 시작 { -->
|
||||
<div id="ssch">
|
||||
<h2><strong><?php echo $q; ?></strong> 검색 결과<span class="ssch_result_total">총 <?php echo $total_count; ?>건</span></h2>
|
||||
<!-- 상세검색 항목 시작 { -->
|
||||
<div id="ssch_frm">
|
||||
<h2><span><strong><?php echo $q; ?></strong> 검색결과</span> (총 <strong><?php echo $total_count; ?></strong> 건 )</h2>
|
||||
<div class="ssch_frm_inner">
|
||||
<form name="frmdetailsearch">
|
||||
<input type="hidden" name="qsort" id="qsort" value="<?php echo $qsort ?>">
|
||||
<input type="hidden" name="qorder" id="qorder" value="<?php echo $qorder ?>">
|
||||
<input type="hidden" name="qcaid" id="qcaid" value="<?php echo $qcaid ?>">
|
||||
<div class="ssch_scharea">
|
||||
<label for="ssch_q" class="sound_only" >검색어</label>
|
||||
<input type="text" name="q" value="<?php echo $q; ?>" id="ssch_q" class="ssch_input" size="40" maxlength="30" placeholder="검색어">
|
||||
<button type="submit" class="btn_submit"><i class="fa fa-search" aria-hidden="true"></i> 검색</button>
|
||||
<button type="button" class="tooltip_icon"><i class="fa fa-question-circle-o" aria-hidden="true"></i><span class="sound_only">설명보기</span></button>
|
||||
<span class="tooltip">
|
||||
상세검색을 선택하지 않거나, 상품가격을 입력하지 않으면 전체에서 검색합니다.<br>
|
||||
검색어는 최대 30글자까지, 여러개의 검색어를 공백으로 구분하여 입력 할수 있습니다.
|
||||
</span>
|
||||
</div>
|
||||
<div class="ssch_option">
|
||||
<strong class="sound_only">검색범위</strong>
|
||||
<input type="checkbox" name="qname" id="ssch_qname" value="1" <?php echo $qname_check?'checked="checked"':'';?>> <label for="ssch_qname">상품명</label>
|
||||
<input type="checkbox" name="qexplan" id="ssch_qexplan" value="1" <?php echo $qexplan_check?'checked="checked"':'';?>> <label for="ssch_qexplan">상품설명</label>
|
||||
<input type="checkbox" name="qbasic" id="ssch_qbasic" value="1" <?php echo $qbasic_check?'checked="checked"':'';?>> <label for="ssch_qbasic">기본설명</label>
|
||||
<input type="checkbox" name="qid" id="ssch_qid" value="1" <?php echo $qid_check?'checked="checked"':'';?>> <label for="ssch_qid">상품코드</label>
|
||||
<strong class="sound_only">상품가격 (원)</strong>
|
||||
<label for="ssch_qfrom" class="sound_only">최소 가격</label>
|
||||
<input type="text" name="qfrom" value="<?php echo $qfrom; ?>" id="ssch_qfrom" class="ssch_input" size="10"> 원 ~
|
||||
<label for="ssch_qto" class="sound_only">최대 가격</label>
|
||||
<input type="text" name="qto" value="<?php echo $qto; ?>" id="ssch_qto" class="ssch_input" size="10"> 원
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<!-- 검색된 분류 시작 { -->
|
||||
<div id="ssch_cate">
|
||||
<ul>
|
||||
<?php
|
||||
$sql = " select b.ca_id, b.ca_name, count(*) as cnt $sql_common $sql_where group by b.ca_id order by b.ca_id ";
|
||||
$result = sql_query($sql);
|
||||
$total_cnt = 0;
|
||||
echo '<li><a href="#" onclick="set_ca_id(\'\'); return false;">전체분류 <span>('.$total_cnt.')</span></a></li>'.PHP_EOL;
|
||||
for ($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<li><a href=\"#\" onclick=\"set_ca_id('{$row['ca_id']}'); return false;\">{$row['ca_name']} (".$row['cnt'].")</a></li>\n";
|
||||
$total_cnt += $row['cnt'];
|
||||
}
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- } 검색된 분류 끝 -->
|
||||
|
||||
<form name="frmdetailsearch">
|
||||
<input type="hidden" name="qsort" id="qsort" value="<?php echo $qsort ?>">
|
||||
<input type="hidden" name="qorder" id="qorder" value="<?php echo $qorder ?>">
|
||||
<input type="hidden" name="qcaid" id="qcaid" value="<?php echo $qcaid ?>">
|
||||
<div class="ssch_scharea">
|
||||
|
||||
<div class="ssch_right">
|
||||
<strong class="sound_only">검색범위</strong>
|
||||
<input type="checkbox" name="qname" id="ssch_qname" value="1" <?php echo $qname_check?'checked="checked"':'';?>> <label for="ssch_qname">상품명</label>
|
||||
<input type="checkbox" name="qexplan" id="ssch_qexplan" value="1" <?php echo $qexplan_check?'checked="checked"':'';?>> <label for="ssch_qexplan">상품설명</label>
|
||||
<input type="checkbox" name="qbasic" id="ssch_qbasic" value="1" <?php echo $qbasic_check?'checked="checked"':'';?>> <label for="ssch_qbasic">기본설명</label>
|
||||
<input type="checkbox" name="qid" id="ssch_qid" value="1" <?php echo $qid_check?'checked="checked"':'';?>> <label for="ssch_qid">상품코드</label>
|
||||
<strong class="sound_only">상품가격 (원)</strong>
|
||||
<label for="ssch_qfrom" class="sound_only">최소 가격</label>
|
||||
<input type="text" name="qfrom" value="<?php echo $qfrom; ?>" id="ssch_qfrom" class="ssch_input" size="10"> 원 ~
|
||||
<label for="ssch_qto" class="sound_only">최대 가격</label>
|
||||
<input type="text" name="qto" value="<?php echo $qto; ?>" id="ssch_qto" class="ssch_input" size="10"> 원
|
||||
</div>
|
||||
<div class="ssch_left">
|
||||
<label for="ssch_q" class="sound_only" >검색어</label>
|
||||
<input type="text" name="q" value="<?php echo $q; ?>" id="ssch_q" class="ssch_input" size="40" maxlength="30" placeholder="검색어">
|
||||
<input type="submit" value="검색" class="btn_submit">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
상세검색을 선택하지 않거나, 상품가격을 입력하지 않으면 전체에서 검색합니다.<br>
|
||||
검색어는 최대 30글자까지, 여러개의 검색어를 공백으로 구분하여 입력 할수 있습니다.
|
||||
</p>
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<!-- } 상세검색 항목 끝 -->
|
||||
|
||||
<!-- 검색된 분류 시작 { -->
|
||||
<div id="ssch_cate" class="sct_ct">
|
||||
<ul>
|
||||
<?php
|
||||
$sql = " select b.ca_id, b.ca_name, count(*) as cnt $sql_common $sql_where group by b.ca_id order by b.ca_id ";
|
||||
$result = sql_query($sql);
|
||||
$total_cnt = 0;
|
||||
for ($i=0; $row=sql_fetch_array($result); $i++) {
|
||||
echo "<li><a href=\"#\" onclick=\"set_ca_id('{$row['ca_id']}'); return false;\">{$row['ca_name']} (".$row['cnt'].")</a></li>\n";
|
||||
$total_cnt += $row['cnt'];
|
||||
}
|
||||
echo '<li><a href="#" onclick="set_ca_id(\'\'); return false;">전체분류 <span>('.$total_cnt.')</span></a></li>'.PHP_EOL;
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- } 검색된 분류 끝 -->
|
||||
<div id="sct_sortlst">
|
||||
<ul id="ssch_sort">
|
||||
<ul id="ssch_sort_all">
|
||||
<li><a href="#" onclick="set_sort('it_sum_qty', 'desc'); return false;">판매많은순</a></li>
|
||||
<li><a href="#" onclick="set_sort('it_price', 'asc'); return false;">낮은가격순</a></li>
|
||||
<li><a href="#" onclick="set_sort('it_price', 'desc'); return false;">높은가격순</a></li>
|
||||
@ -71,7 +63,8 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
<li><a href="#" onclick="set_sort('it_use_cnt', 'desc'); return false;">후기많은순</a></li>
|
||||
<li><a href="#" onclick="set_sort('it_update_time', 'desc'); return false;">최근등록순</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- } 상세검색 항목 끝 -->
|
||||
</div>
|
||||
<!-- 검색결과 시작 { -->
|
||||
<div>
|
||||
<?php
|
||||
@ -83,13 +76,13 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
$list->set_query(" select * $sql_common $sql_where {$order_by} limit $from_record, $items ");
|
||||
$list->set_is_page(true);
|
||||
$list->set_view('it_img', true);
|
||||
$list->set_view('it_id', true);
|
||||
$list->set_view('it_name', true);
|
||||
$list->set_view('it_basic', 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);
|
||||
$list->set_view('star', true);
|
||||
echo $list->run();
|
||||
}
|
||||
else
|
||||
@ -111,11 +104,9 @@ if (!defined('_GNUBOARD_')) exit; // 개별 페이지 접근 불가
|
||||
?>
|
||||
</div>
|
||||
<!-- } 검색결과 끝 -->
|
||||
|
||||
</div>
|
||||
<!-- } 검색 끝 -->
|
||||
|
||||
|
||||
<script>
|
||||
function set_sort(qsort, qorder)
|
||||
{
|
||||
@ -131,4 +122,18 @@ function set_ca_id(qcaid)
|
||||
f.qcaid.value = qcaid;
|
||||
f.submit();
|
||||
}
|
||||
|
||||
$(function(){
|
||||
//tooltip
|
||||
$(".tooltip_icon").click(function(){
|
||||
$(this).next(".tooltip").fadeIn(400);
|
||||
}).mouseout(function(){
|
||||
$(this).next(".tooltip").fadeOut();
|
||||
});
|
||||
});
|
||||
|
||||
// 검색옵션
|
||||
$("#ssch_sort_all li a").click(function() {
|
||||
$(this).parent().addClass('active');
|
||||
});
|
||||
</script>
|
||||