<?
//========================================
// dehead(config/function/lib) Include
//========================================
include $_SERVER['DOCUMENT_ROOT']."/front/include/dehead.php";

//========================================
// Meta Tag
//========================================
$store = ($store) ? $store : "A";
$metaTitle = $metaInfo['branch_'.$store]['title'];
$metaDescription = $metaInfo['branch_'.$store]['description'];
$metaKeyword = $metaInfo['branch_'.$store]['keyword'];
$metaImage = $metaInfo['branch']['image'];
$metaNav	= $metaInfo['branch_'.$store]['nav'];

//========================================
// Class Connect
//========================================
$Db = new Db(); // 데이터 베이스 클래스

//========================================
// Data Process
//========================================
$param = array('no' => PARAMETER_NO, 'show' => PARAMETER_Y, 'del' => PARAMETER_N, 'code' => "introduce", 'store' => $store);
//echo PARAMETER_NO;
//========================================
// Search Query
//========================================
$list = $Db->query("SELECT A.info, B.attach, B.attach_ori, B.mod_date FROM $TABLE_INTRODUCE A 
LEFT JOIN $TABLE_ATTACH B ON A.no = B.wno AND B.code = :code
WHERE A.no > :no AND A.d_show = :show AND A.del = :del AND A.store = :store AND B.del = 'N' ORDER BY B.seq ", $param);
$Db->CloseConnection;
/*
if(bip == 'Y'){
	foreach($list as $key => $val){
		echo $key."<br>";
		foreach($val as $i => $j){
			echo $i." =>".$j."<br>";
		}
	}
}*/
//========================================
// header Include
//========================================
include PATH_INCLUDE."header.php";
?>

        <div id="container">
            <div class="sub_visual_wrap branch">
                <div class="inner_box">
                    <div class="location">
                        <a href="/"><img src="<?=PATH_IMAGES?>/common/ico_home.png" alt="HOME" /></a> &nbsp;&gt;&nbsp;
                        <?php
						if($metaNav[4]){ echo "<span>".$metaNav[4]."</span> &nbsp;&gt;&nbsp;"; }
						if($metaNav[3]){ echo "<span>".$metaNav[3]."</span> &nbsp;&gt;&nbsp;"; }
						if($metaNav[2]){ echo "<span>".$metaNav[2]."</span> &nbsp;&gt;&nbsp;"; }
						if($metaNav[1]){ echo "<span>".$metaNav[1]."</span> &nbsp;&gt;&nbsp;"; }
						echo "<strong>".$metaNav[0]."</strong>";
						?>
                    </div>
                    <h1 class="tit">지점소개</h1>
                    <p>삼성드림이비인후과 Different Story</p>
                </div>
            </div>
            <div id="contents">
                <div class="branch_wrap">
                    <div class="tab_style1 five">
                        <ul id="storeBtn">
                        <? foreach ($storeNameArr as $key => $val) { ?>
                            <li <? if($store === $key) echo "class=\"on\""; ?>><a href="<? echo ($store == $key) ? "#self" : "?store=$key"; ?>"><?=$val?></a></li>
                        <? } ?>
                        </ul> 
                    </div>
                    <div class="branch_big_img_wrap">
                        <ul id="sliderView" class="slider">
                        <?
                        foreach($list as $key => $val){
                            $info = stripslashes($val['info']);
                            $imgPath = $pathInfo['introduce']['file'].DateConv($val['mod_date'], 3)."/".$val['attach'];
                        ?>
                            <li>
                                <img src="<?=$imgPath?>" alt="삼성드림이비인후과 사진" />
                                <div class="tit"><?=$info?></div>
								<?php
								if($store == 'E'){?>
									<!-- Google 리마케팅 태그 코드 -->
<!--------------------------------------------------
리마케팅 태그를 개인식별정보와 연결하거나 민감한 카테고리와 관련된 페이지에 추가해서는 안 됩니다. 리마케팅 태그를 설정하는 방법에 대해 자세히 알아보려면 다음 페이지를 참조하세요. http://google.com/ads/remarketingsetup
--------------------------------------------------->
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = 1014556205;
var google_custom_params = window.google_tag_params;
var google_remarketing_only = true;
/* ]]> */
</script>
<script type="text/javascript" src="//www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<div style="display:inline;">
<img height="1" width="1" style="border-style:none;" alt="구글" src="//googleads.g.doubleclick.net/pagead/viewthroughconversion/1014556205/?value=0&amp;guid=ON&amp;script=0"/>
</div>
</noscript>	
								<?}
								?>
                            </li>
                        <? } ?>
                        </ul>
                    </div>
<style>
.tab_style1.five ul li{
	width:16.66%;
}
.branch_small_img_wrap .slider .b_thumbnail{
width:331px; height:188px;
background-position:center;
background-size:cover;

}
@media screen and (max-width: 1620px){
	.branch_small_img_wrap .slider .b_thumbnail {
		width:195px;
		height:130px;
	}
}
@media screen and (max-width: 640px){
        .branch_small_img_wrap .slider .b_thumbnail {
                width:100%;
        }
}

</style>
                    <div class="branch_small_img_wrap">
                        <div id="sliderList" class="slider">
                            <span>
                            <?
                            foreach ($list as $key => $val){
                                if($key > 0 && $key%4 == 0){
                                    echo "</span>\n<span>\n";
                                }
                                $imgPath = $pathInfo['introduce']['file'].DateConv($val['mod_date'], 3)."/".$val['attach'];
                            ?>
                                <a href="#self" <? if($key == 0) echo "class=\"on\"";?>>
					<!--img src="<?=$imgPath?>" width="331" height="158" alt="" /-->
					<div class="b_thumbnail" style="background-image:url('<?=$imgPath?>')"></div>
				</a>
                            <? } ?>
                        </div>
                        <a href="#self" class="prev"><img src="<?=PATH_IMAGES?>/introduction/btn_prev1.png" alt="이전 이미지" /></a>
                        <a href="#self" class="next"><img src="<?=PATH_IMAGES?>/introduction/btn_next1.png" alt="다음 이미지" /></a>
                    </div>
                </div>
            </div>
        </div><!-- end : container -->
<?
if($store == 'E'){
?>
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = 1014556205;
var google_custom_params = window.google_tag_params;
var google_remarketing_only = true;
/* ]]> */
</script>
<script type="text/javascript" src="//www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<div style="display:inline;">
<img height="1" width="1" style="border-style:none;" alt="구글" src="//googleads.g.doubleclick.net/pagead/viewthroughconversion/1014556205/?value=0&amp;guid=ON&amp;script=0"/>
</div>
</noscript>
<?
}
?>
<?
//========================================
// quick bar Include
//========================================
include PATH_INCLUDE."quick.php";

//========================================
// footer Include
//========================================
include PATH_INCLUDE."footer.php";
?>
