﻿<!--browser title
document.title='Animate Shop - 일본 구매대행 전문 쇼핑몰';
//-->
<!--//dreamweaver basic 
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
<!--popup
function pop1(pop,width,height,flag)
{
	var url = pop;
	var wd = width;
	var he = height;
	var scw = (screen.width-wd)/2;
	var sch = (screen.height-he)/2;
	

	if (flag == 0 )
	{
		window.open(url,"0","toolbar=0,menubar=0,scrollbars=no,resizable=no,width=" + wd +",height=" + he + ",top="+sch+",left="+scw+";")
	}
	else
	{
		window.open(url,"0","toolbar=0,menubar=0,scrollbars=yes,resizable=no,width=" + wd +",height=" + he + ",top="+sch+",left="+scw+";")
	}
}
function pop11(){
	window.open('/Popup/pop_privacy.htm','','scrollbars=no,status=no,width=500,height=420,left=0,top=0');					
}
function mail_no1(){
	window.open('/Popup/pop_mail_no.htm','','scrollbars=no,status=no,width=500,height=510,left=0,top=0');					
}

//-->
<!--show or hide menu
var currdiv	= null;

// Question 항목만 Show or Hide 함수
function showhide_title(titleAll) {
	if(titleAll.style.display == "none") {
		if (currdiv != null){
			currdiv.style.display = "none" ;
		}
		titleAll.style.display = "" ;
		currdiv	= titleAll;
	} else {
		titleAll.style.display = "none" ;
	}
}
//-->


//팝업 레이어 함수
function OpenText(num) {
	menu = eval("document.all.leftMenu.style");
	menu.visibility="visible";
}

function CloseText(num) {
	menu = eval("document.all.leftMenu.style");	
	menu.visibility="hidden";
}

//플래시 삽입 스크립트
// s: Source Url
// d: Flash Id
// w: Source Width
// h: Source Height
// t: Wmode ("" for none, transparent, opaque ...)
function flash_mode(s,d,w,h,t){
	return "<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0\" width="+w+" height="+h+" id="+d+"><param name=wmode value="+t+" /><param name=movie value="+s+" /><param name=quality value=high /><embed src="+s+" quality=high wmode="+t+" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/shockwave/download/index.cgi?p1_prod_version=shockwaveflash\" width="+w+" height="+h+"></embed></object>";
}

// Write Document Contents(Flash)
function documentwrite(src){
	document.write(src);
}

//주민번호 체크
function jumin_check(f_usernum1,f_usernum2)
{ 
	check_jumin = false; 
  // 잘못된 생년월일을 검사합니다. 
  b_Year = (f_usernum2.charAt(0) <= "2") ? "19" : "20" 
  /* 2000년도부터 성구별 번호가 바뀌였슴으로 구별수가 2보다 작다면 
  1900년도 생이되고 2보다 크다면 2000년도 이상생이 됩니다. 
  단 1800년도 생은 계산에서 제외합니다.*/ 
 
  b_Year += f_usernum1.substr(0, 2) 
  // 주민번호의 앞에서 2자리를 이어서 4자리의 생년을 저장합니다. 
  b_Month = f_usernum1.substr(2, 2) - 1 
  // 달을 구합니다. 1을 뺀것은 자바스크립트에서는 1월을 0으로 표기하기 때문입니다. 
  b_Date = f_usernum1.substr(4, 2) 
  b_sum = new Date(b_Year, b_Month, b_Date) 
  if ( b_sum.getYear() % 100 != f_usernum1.substr(0,2) || b_sum.getMonth() != b_Month || b_sum.getDate() != b_Date) { 
  return check_jumin 
  // 생년월일의 타당성을 검사하여 거짓이 있을시 에러메세지를 나타냄 
  }
  total = 0 
  temp = new Array(13) 
  for(i=1; i<=6; i++) temp[i] = f_usernum1.charAt(i-1) 
  for(i=7; i<=13; i++) temp[i] = f_usernum2.charAt(i-7) 
  for(i=1; i<=12; i++) { 
  k = i + 1 
  if(k >= 10) k = k % 10 + 2 
  /* 각 수와 곱할 수를 뽑아냅니다. 곱수가 만일 10보다 크거나 같다면 
  계산식에 의해 2로 다시 시작하게 됩니다. */ 
  total = total + (temp[i] * k) 
  // 각 자리수와 계산수를 곱한값을 변수 total에 누적합산시킵니다. 
  } 
 
  last_num = (11- (total % 11)) % 10 
  // 마지막 계산식을 변수 last_num에 대입합니다. 
  if(last_num == temp[13]) check_jumin = true 
  // laster_num이 주민번호의마지막수와 같은면 참을 틀리면 거짓을 반환합니다. 
  else check_jumin = false 
  return check_jumin 
} 


// 쿠키체크
function getCookie(Name) {
  var search = Name + "="
  if (document.cookie.length > 0) { // 쿠키가 설정되어 있다면
    offset = document.cookie.indexOf(search)
    if (offset != -1) { // 쿠키가 존재하면
      offset += search.length
      // set index of beginning of value
      end = document.cookie.indexOf(";", offset)
      // 쿠키 값의 마지막 위치 인덱스 번호 설정
      if (end == -1)
        end = document.cookie.length
      return unescape(document.cookie.substring(offset, end))
    }
  }
  return "";
}

//쿠키체크하여 팝업
function OpenPopupChk(index, width, height, top, left)
{
	if(getCookie("mainPopup" + index) != "done")
		window.open('/Popup/Popup.aspx?index=' + index, 'mainPopup' + index, 'scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + left + ',top=' + top);
}