<?php
	//자동 로그인 체크
	include $_SERVER['DOCUMENT_ROOT'].'/common/auto_login_chk.php';
 ?>
 <?php include_once($_SERVER['DOCUMENT_ROOT'].'/include/inc_top.php'); ?>
 <header>
	 <div class="header--wrapper">
		 <div class="header--contents">
			 <h1 class="logo" onclick="link('/')"></h1>
			 <div class="gnb--wrapper">
				 <a href="/company/company.php" class="<?=(left($MENU_ACTV,1) == 1 ? "actv" : "")?>">이차조아란?</a>
				 <a href="/sell/search.php" class="<?=(left($MENU_ACTV,1) == 2 ? "actv" : "")?>">내차 사고이력 조회</a>
				 <a href="/customer/notice_list.php" class="<?=(left($MENU_ACTV,1) == 3 ? "actv" : "")?>">고객 센터</a>
			 </div>
			 <div class="log--menu--wrap">
			 <?php
			     if(!empty($_SESSION['s_cd_userid'])){
			 ?>
			 	<!-- <a href="/memeber/mypage.php">마이페이지</a> -->
			 	<a href="/member/standby_list.php">마이페이지</a>
				 <!-- <a href="/member/join.php">회원가입</a> -->
				 <a href="/member/logout.php" class="on">로그아웃</a>
			<?php } else { ?>
				<a href="/member/join.php">회원가입</a>
				<a href="/member/login.php" class="on">로그인</a>
			<?php } ?>
			 </div>
		 </div>
	 </div>
 </header>

<!-- <header>
	<div id="header_wrap">
		<h1><a href="/index.php">UPRO</a></h1>
		<nav>
			<ul>
				<li><a href="#">회사소개</a>
					<ul>
						<li><a href="/company/greeting.php">인사말</a></li>
						<li><a href="/company/location.php">찾아오시는 길</a></li>
					</ul>
				</li>
				<li><a href="#">내차 팔기</a>
					<ul>
						<li><a href="/sell/sell.php">내차팔기</a></li>
					</ul>
				</li>
				<li><a href="#">서비스 안내</a>
					<ul>
						<li><a href="/service/guide.php">이용안내</a></li>
					</ul>
				</li>
				<li><a href="#">고객센터</a>
					<ul>
						<li><a href="/customer/faq.php">자주묻는 질문</a></li>
						<li><a href="/customer/notice_list.php">공지사항</a></li>
						<li><a href="/customer/inquiry.php">1:1 문의</a></li>
					</ul>
				</li>
			</ul>
		</nav>
		<div class="area_link"> -->
<?
    if(!empty($_SESSION['s_nm_email']) && ($_SESSION['s_ds_type'] == "A0" || $_SESSION['s_ds_type'] == "B0")){
?>
			<!-- <span><a href="#" id="logout">로그아웃</a></span>
			<span><a href="/mypage/mypage.php">마이페이지</a></span> -->
<?
	}else if(!empty($_SESSION['s_cd_dealer']) && ($_SESSION['s_ds_type'] == "D0" || $_SESSION['s_ds_type'] == "D1")){
?>
			<!-- <span><a href="#" id="logout">로그아웃</a></span>
			<span><a href="/mypage/dealer.php">마이페이지</a></span> -->
<?
//	}else if(!empty($_SESSION['s_nomem_hp']) && $_SESSION['s_ds_type'] == "C0"){
?>
			<!--span><a href="#" id="logout">로그아웃</a></span>
			<span><a href="/">비회원</a></span-->
<?
    }else{
?>
			<!-- <span><a href="/member/login.php">로그인</a></span>
			<span><a href="/member/join_type.php">회원가입</a></span>
            <span><a href="/sell/sell_nonmember_search.php">비회원 차량조회</a></span>
            <span><a href="/member/login_dealer.php">딜러전용</a></span> -->
<?
    }
?>
		<!-- </div>
	</div>
</header>
<script>
    $(document).ready(function() {
		$("#logout").on("click", function(){
            location.href = "/member/login_proc.php?mode=logout";
			return false;
        });
    });
</script> -->
