//flashMovie(Ãâ·Â¿µ¿ªID,ÇÃ·¡½ÃÆÄÀÏ°æ·Î,WIDTH,HEIGHT,FLASHVARS,BackgroundColor,WMOD)

function flashMovie(fid,src,wid,hei,fvs,bgc,wmd) {
  this.fPrint = '';
  this.Id = document.getElementById(fid);
  this.Src = src;
  if(wid == 0){
    this.Width = '100%';
  }
  else{
    this.Width = wid;
  }
  if(hei == 0){
    this.Height = '100%';
  }
  else{
    this.Height = hei;
  }
  this.FlashVars = (fvs != undefined)? fvs :'';
  this.Wmod = (wmd != undefined)? wmd :'';
  this.BGC = (bgc != undefined)? bgc :'';
  if(isObject(Id)) {
    fPrint = '<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0"';
    fPrint += ' width="'+Width+'"';
    fPrint += ' height="'+Height+'">';
    fPrint += '<param name="allowScriptAccess" value="always">';
    fPrint += '<param name="movie" value="'+Src+'">';
    fPrint += '<param name="menu" value="false" />';
    fPrint += '<param name="quality" value="high">';
	fPrint += (BGC != null) ? '<param name="bgcolor" value="'+BGC+'">' : '';
    fPrint += (FlashVars != null) ? '<param name="FlashVars" value="'+FlashVars+'">' : '';
    fPrint += (Wmod != null) ? '<param name="wmode" value="'+Wmod+'">' : '';
    fPrint += '<embed';
    fPrint += fPrint + ' src="'+Src+'"';
    fPrint += (FlashVars != null) ? ' FlashVars="'+FlashVars+'"' : '';
    fPrint += (Wmod != null) ? ' wmode="'+Wmod+'"' : '';
    fPrint += ' quality="high"';
	fPrint += (BGC != null) ? ' bgcolor="'+BGC+'"' : '';
    fPrint += ' allowScriptAccess="always"';
    fPrint += ' pluginspage="http://www.macromedia.com/go/getflashplayer"';
    fPrint += ' type="application/x-shockwave-flash"';
    fPrint += ' width="'+Width+'"';
    fPrint += ' height="'+Height+'"';
    fPrint += '></embed>';
    fPrint += '</object>';
    Id.innerHTML = fPrint;
  }
}

function isObject(a) {
    return (a && typeof a == 'object');
}





//¿©±âºÎÅÍ ¾Æ·¡´Â ÇÃ·¡½Ã ¸µÅ©¿¡ °ü°èµÈ ºÎºÐÀÔ´Ï´Ù.

//¸ÅÈ­¼ö ÀÌ¾ß±â
menu1 ="/story/meahwasu.asp";
menu11 ="/story/meahwasu.asp";
menu12 ="/story/why.asp";
menu13 ="/story/apricot.asp";
menu14 ="/story/notice_list.asp";
menu15 ="/story/faq_list.asp";


//¸ÅÈ­¼ö ¼îÄÉÀÌ½º
menu2 ="/showcase/cf.asp";
menu21 ="/showcase/cf.asp";
menu22 ="/showcase/print.asp";
menu23 ="/showcase/behind.asp";


//¸ÅÈ­¼ö ÀÌº¥Æ®
menu3 ="/event/event_ing.asp";
menu31 ="/event/event_ing.asp";
menu32 ="/event/event_pass.asp";
menu33 ="/event/winner_list.asp";


//Sweet Time
menu4 ="/sweet/reply_list.asp";
menu41 ="/sweet/reply_list.asp";
menu42 ="/sweet/sweet_list.asp";
menu43 ="/sweet/short_list.asp";
menu44 ="/sweet/album_list.asp";


//HOME
util1 ="/index.asp";


//Log-In
util2 ="javascript:Login()";
util3 ="/member/logout.asp";


//Join
util4 ="/member/join.asp";


//My Info
util5 ="/member/myinfo.asp";


//Contact us
util6 ="/common/contact.asp";


//Jinro
util7 ="javascript:openNewWindow('http://www.jinro.com')";


//¼úÀÇ ¸ðµç°Í
util8 ="javascript:openNewWindow('http://www.jinro.com/alcohol/story_01.asp')";


//Áø·Î¿ª»ç°ü
util9 ="javascript:openNewWindow('http://www.jinro.com/museum/museum.asp')";


//°³ÀÎÁ¤º¸º¸È£Á¤Ã¥
util10 ="http://www.maehwasu.com/member/login.asp";


//ÀÌ¿ë¾à°ü
util11 ="http://www.maehwasu.com/member/join.asp";


//»çÀÌÆ®¸Ê
util12 ="/util/sitemap.asp";


function util(){
	var url = "";
	var depth = arguments.length;
	try {
		if(depth==0) return;
		else if(depth==1) url = eval("util"+arguments[0]);
		else if(depth==2) url = eval("util"+arguments[0]+arguments[1]);
		else if(depth==3) url = eval("util"+arguments[0]+arguments[1]+arguments[2]);
		location.href = url;
	}catch(e) { alert("ÁØºñÁßÀÔ´Ï´Ù."); }
}

function menu(){
	var url = "";
	var depth = arguments.length;
	try {
		if(depth==0) return;
		else if(depth==1) url = eval("menu"+arguments[0]);
		else if(depth==2) url = eval("menu"+arguments[0]+arguments[1]);
		else if(depth==3) url = eval("menu"+arguments[0]+arguments[1]+arguments[2]);
		location.href = url;
	}catch(e) { alert("ÁØºñÁßÀÔ´Ï´Ù."); }
}

function openNewWindow(url) {
	window.open(url)
}
