상품리스트 및 상세보기 스킨화 작업 1차

This commit is contained in:
chicpro
2013-09-23 14:49:02 +09:00
parent 4735cb9050
commit 47135be416
22 changed files with 1035 additions and 631 deletions

View File

@ -21,24 +21,24 @@ if (!($it['ca_use'] && $it['it_use'])) {
}
// 분류 테이블에서 분류 상단, 하단 코드를 얻음
$sql = " select ca_include_head, ca_include_tail, ca_hp_cert_use, ca_adult_cert_use from {$g5['g5_shop_category_table']} where ca_id = '{$it['ca_id']}' ";
$sql = " select ca_include_head, ca_include_tail, ca_cert_use, ca_adult_use from {$g5['g5_shop_category_table']} where ca_id = '{$it['ca_id']}' ";
$ca = sql_fetch($sql);
if(!$is_admin) {
// 본인확인체크
if($ca['ca_hp_cert_use'] && !$member['mb_hp_certify']) {
if($ca['ca_cert_use'] && !$member['mb_certify']) {
if($is_member)
alert('회원정보 수정에서 휴대폰 본인확인 후 이용해 주십시오.');
alert('회원정보 수정에서 본인확인 후 이용해 주십시오.');
else
alert('휴대폰 본인확인된 로그인 회원만 이용할 수 있습니다.');
alert('본인확인된 로그인 회원만 이용할 수 있습니다.');
}
// 성인인증체크
if($ca['ca_adult_cert_use'] && !$member['mb_adult']) {
if($ca['ca_adult_use'] && !$member['mb_adult']) {
if($is_member)
alert('휴대폰 본인확인으로 성인인증된 회원만 이용할 수 있습니다.\\n회원정보 수정에서 휴대폰 본인확인을 해주십시오.');
alert('본인확인으로 성인인증된 회원만 이용할 수 있습니다.\\n회원정보 수정에서 본인확인을 해주십시오.');
else
alert('휴대폰 본인확인으로 성인인증된 회원만 이용할 수 있습니다.');
alert('본인확인으로 성인인증된 회원만 이용할 수 있습니다.');
}
}
@ -79,10 +79,10 @@ else
// 분류 위치
// HOME > 1단계 > 2단계 ... > 6단계 분류
$ca_id = $it['ca_id'];
include G5_SHOP_PATH.'/navigation.inc.php';
include G5_SHOP_SKIN_PATH.'/navigation.skin.php';
// 이 분류에 속한 하위분류 출력
include G5_SHOP_PATH.'/listcategory.inc.php';
include G5_SHOP_SKIN_PATH.'/listcategory.skin.php';
if ($is_admin) {
echo '<div class="sit_admin"><a href="'.G5_ADMIN_URL.'/shop_admin/itemform.php?w=u&amp;it_id='.$it_id.'" class="btn_admin">상품 관리</a></div>';
@ -94,73 +94,6 @@ if ($is_admin) {
// 상단 HTML
echo '<div id="sit_hhtml">'.stripslashes($it['it_head_html']).'</div>';
// 이전 상품보기
$sql = " select it_id, it_name from {$g5['g5_shop_item_table']} where it_id > '$it_id' and SUBSTRING(ca_id,1,4) = '".substr($it['ca_id'],0,4)."' and it_use = '1' order by it_id asc limit 1 ";
$row = sql_fetch($sql);
if ($row['it_id']) {
$prev_title = '이전상품<span class="sound_only"> '.$row['it_name'].'</span>';
$prev_href = '<a href="./item.php?it_id='.$row['it_id'].'" class="btn01">';
$prev_href2 = '</a>'.PHP_EOL;
} else {
$prev_title = '';
$prev_href = '';
$prev_href2 = '';
}
// 다음 상품보기
$sql = " select it_id, it_name from {$g5['g5_shop_item_table']} where it_id < '$it_id' and SUBSTRING(ca_id,1,4) = '".substr($it['ca_id'],0,4)."' and it_use = '1' order by it_id desc limit 1 ";
$row = sql_fetch($sql);
if ($row['it_id']) {
$next_title = '다음 상품<span class="sound_only"> '.$row['it_name'].'</span>';
$next_href = '<a href="./item.php?it_id='.$row['it_id'].'" class="btn01">';
$next_href2 = '</a>'.PHP_EOL;
} else {
$next_title = '';
$next_href = '';
$next_href2 = '';
}
// 관리자가 확인한 사용후기의 갯수를 얻음
$sql = " select count(*) as cnt from `{$g5['g5_shop_item_use_table']}` where it_id = '{$it_id}' and is_confirm = '1' ";
$row = sql_fetch($sql);
$item_use_count = $row['cnt'];
// 상품문의의 갯수를 얻음
$sql = " select count(*) as cnt from `{$g5['g5_shop_item_qa_table']}` where it_id = '{$it_id}' ";
$row = sql_fetch($sql);
$item_qa_count = $row['cnt'];
// 관련상품의 갯수를 얻음
$sql = " select count(*) as cnt from {$g5['g5_shop_item_relation_table']} a left join {$g5['g5_shop_item_table']} b on (a.it_id2=b.it_id and b.it_use='1') where a.it_id = '{$it['it_id']}' ";
$row = sql_fetch($sql);
$item_relation_count = $row['cnt'];
// 상품 선택옵션 갯수
$sql = " select count(*) as cnt from {$g5['g5_shop_item_option_table']} where it_id = '{$it['it_id']}' and io_type = '0' and io_use = '1' ";
$row = sql_fetch($sql);
$opt_count = $row['cnt'];
// 상품 추가옵션 갯수
$sql = " select count(*) as cnt from {$g5['g5_shop_item_option_table']} where it_id = '{$it['it_id']}' and io_type = '1' and io_use = '1' ";
$row = sql_fetch($sql);
$spl_count = $row['cnt'];
// 고객선호도 별점수
$star_score = get_star_image($it['it_id']);
// 선택 옵션
$option_1 = get_item_options($it['it_id'], $it['it_option_subject']);
// 추가 옵션
$option_2 = get_item_supply($it['it_id'], $it['it_supply_subject']);
// 소셜 관련
$sns_title = get_text($it['it_name']).' | '.get_text($config['cf_title']);
$sns_url = G5_SHOP_URL.'/item.php?it_id='.$it['it_id'];
$sns_share_links .= get_sns_share_link('facebook', $sns_url, $sns_title, G5_SHOP_URL.'/img/sns_fb2.png').' ';
$sns_share_links .= get_sns_share_link('twitter', $sns_url, $sns_title, G5_SHOP_URL.'/img/sns_twt2.png').' ';
$sns_share_links .= get_sns_share_link('googleplus', $sns_url, $sns_title, G5_SHOP_URL.'/img/sns_goo2.png');
// 보안서버경로
if (G5_HTTPS_DOMAIN)
$action_url = G5_HTTPS_DOMAIN.'/'.G5_SHOP_DIR.'/cartupdate.php';
@ -172,13 +105,15 @@ else
<div id="sit">
<!-- 상품 구입폼 시작 { -->
<?php include_once(G5_SHOP_SKIN_PATH.'/item.form.skin.php'); ?>
<!-- } 상품 구입폼 끝 -->
<?php
// 상품 구입폼
include_once(G5_SHOP_SKIN_PATH.'/item.form.skin.php');
?>
<!-- 상품 상세정보 시작 { -->
<?php include_once(G5_SHOP_SKIN_PATH.'/item.info.skin.php'); ?>
<!-- } 상품 상세정보 끝 -->
<?php
// 상품 상세정보
include_once(G5_SHOP_SKIN_PATH.'/item.info.skin.php');
?>
</div>
@ -186,7 +121,6 @@ else
// 하단 HTML
echo stripslashes($it['it_tail_html']);
?>
<!-- } 상품 상세보기 끝 -->
<?php
if ($ca['ca_include_tail'])