function goClose(){
	if(confirm("Ã¢À» ´ÝÀ¸½Ã°Ú½À´Ï±î?")) {
		window.close();	
	}
}


function getRadioValue(objForm,objRadio,dV) {

	// ¶óµð¿À¹öÆ°ÀÇ °á°ú°ªÀ» È®ÀÎ
	// objForm - ¶óµð¿À¹öÆ°ÀÌ ¼ÓÇÑ ÆûÀÇ ÀÌ¸§
	// objRadio - ¶óµð¿À¹öÆ°ÀÇ ÀÌ¸§
	// dV - ¼±ÅÃÇ×¸ñÀÌ ¾øÀ» °æ¿ìÀÇ ¸®ÅÏ°ª
	// return - ¼±ÅÃÇ×¸ñÁöÁ¤½Ã ¼±ÅÃµÈ °ª, ¹ÌÁöÁ¤½Ã dV

	var defaultValue;
	if (getRadioValue.arguments.length>=3) defaultValue=dV;
	else defaultValue=-1

	var iSellCode,bNoItem;
	iSellCode=defaultValue;
	if (objForm=='') objForm="_no form_"
	if (objRadio=='') objRadio="_no radio_"
	if (document.forms(objForm)==null) return iSellCode;
	if (document.forms(objForm).elements(objRadio)==null) return iSellCode;

	var i;
	bNoItem=true;
	for (i=0;i<1000;i++) {
		if (document.forms(objForm).elements(objRadio)[i]==null) break;
		bNoItem=false;
		if (document.forms(objForm).elements(objRadio)[i].checked) {
			iSellCode=document.forms(objForm).elements(objRadio)[i].value;
			break;
		}
	}
	if (bNoItem) {
		if (document.forms(objForm).elements(objRadio)!=null) {
			if (document.forms(objForm).elements(objRadio).checked) {
				iSellCode=document.forms(objForm).elements(objRadio).value;
			}
		}
	}
	return iSellCode;
}

function m2p(m) {
	// 'Á¦°ö¹ÌÅÍ'¸¦ 'Æò'À¸·Î º¯È¯
	// m - 'Á¦°ö¹ÌÅÍ'°ª
	// return - 'Æò'À¸·Î º¯È¯µÈ °ª
	return Math.round(m*0.3025*100)/100;
}
function p2m(p) {
	// 'Æò'À» 'Á¦°ö¹ÌÅÍ'·Î º¯È¯
	// p - 'Æò'°ª
	// return - 'Á¦°ö¹ÌÅÍ'·Î º¯È¯µÈ °ª
	return Math.round(p/0.3025*100)/100;
}
function m2y(m) {
	// '¹ÌÅÍ'¸¦ '¾ßµå'À¸·Î º¯È¯
	// m - '¹ÌÅÍ'°ª
	// return - '¾ßµå'À¸·Î º¯È¯µÈ °ª
	return Math.round(m*1.0936*100)/100;
}
function y2m(y) {
	// '¾ßµå'À» '¹ÌÅÍ'·Î º¯È¯
	// y - '¾ßµå'°ª
	// return - '¹ÌÅÍ'·Î º¯È¯µÈ °ª
	return Math.round(y*0.9144*100)/100;
}
function selectAll(obj) {
	// object (text,textarea) ¿¡ Æ÷Ä¿½º¸¦ ÁöÁ¤ÇÏ°í ¸ðµç ¿µ¿ªÀ» ¼±ÅÃÇÔ
	// obj - object (JAVA object)
	// return - ¾øÀ½

	try{
	if (obj.type!='hidden'&&obj.style.display!='none') {
		obj.focus();
		if (!obj.readOnly) obj.select();
	}
	}catch(e){}
}
function toNextObj(obj1,len,obj2) {
	// obj1 (text) ÀÇ ÀÔ·ÂÀÌ len ÀÏ°æ¿ì obj2 ·Î Æ÷Ä¿½º¸¦ ÀÌµ¿
	// obj1 - Å×½ºÆ®µÉ object
	// len - ´ÙÀ½ object ·Î ³Ñ¾î°¥ ±æÀÌ
	// obj2 - ´ÙÀ½ object
	// return - none
	// ºñ°í - onkeyup event function ¿¡¼­ »ç¿ëÇÒ ¼ö ÀÖÀ½

	if (obj1!=null&&obj2!=null) {
		if (obj1.value.length>=len) selectAll(obj2);
	}
}

function checkFunc(func,value) {
	var aTemp;
	if (func=='') return '';
	var aTemp=(func+'////////').split("/");
	switch (aTemp[0]) {
	case 'noneorlen' :
		if (value.length==0||value.length==parseInt(aTemp[1])) return '';
		return aTemp[2];
	case 'checklen' :
		if (value.length==parseInt(aTemp[1])) return '';
		return aTemp[2];
	default          :
		return '¾Ë ¼ö ¾ø´Â ÇÔ¼öÀû¿ë';
	}
}

function checkVar(obj,strNE,iFloat,strNN,iMin,iMax,strOF) {

	// ÀÔ·Â°ªÀÇ À¯È¿¼º¿©ºÎ¸¦ È®ÀÎÇÔ
	// obj - È®ÀÎÇÒ object
	// strNE - ÀÔ·Â°ªÀÌ °ø¹éÀÏ°æ¿ì(½ºÆäÀÌ½º¸¸ ÀÔ·ÂÇÑ °æ¿ì Æ÷ÇÔ) Ç¥½ÃÇÒ ¿À·ù ³»¿ë. ÀÌ°ªÀÌ '' ÀÏ°æ¿ì ¿À·ù¸¦ ³»Áö ¾ÊÀ½
	// ------------- ÀÌÇÏ´Â strNN ±îÁö ÁöÁ¤½Ã À¯È¿
	// ¼ýÀÚ È®ÀÎ ºÎºÐÀ¸·Î ¼ýÀÚµÚ ¹®ÀÚ°¡ ÀÔ·ÂµÇ¾îµµ ¼ýÀÚ·Î º¯°æ½ÃÅ²´Ù. ('223f'->'223')
	// À½¼ö´Â ÀÔ·ÂÇÒ ¼ö ¾øÀ½
	// iFloat - ¼Ò¼ýÁ¡ÀÌÇÏ ÀÚ¸® - ÀÌ ÀÌÇÏ·Î ÀÔ·ÂµÈ °ªÀº ¶ó¿îµåµÊ. 9 ÀÏ°æ¿ì Çü½ÄÀ» º¯È­½ÃÅ°Áö ¾ÊÀ½(ÀüÈ­¹øÈ£µîÀÇ  ÀÔ·Â½Ã)
	// strNN - ¼ýÀÚ·Î º¯°æÀÌ µÇÁö ¾ÊÀ» ¶§ÀÇ Ç¥½ÃÇÒ ¿À·ù ³»¿ë
	// ------------- ÀÌÇÏ´Â strOF ±îÁö ÁöÁ¤½Ã À¯È¿
	// º¯°æµÈ ¼öÄ¡ÀÇ À¯È¿¹üÀ§¸¦ È®ÀÎ
	// iMin - ¼öÄ¡ÀÇ ÃÖ¼Ò°ª
	// iMax - ¼öÄ¡ÀÇ ÃÖ´ë°ª
	// strOF - ¹üÀ§¸¦ ¹þ¾î³µÀ»¶§ Ç¥½ÃÇÒ ¿À·ù ³»¿ë
	// return - Á¤»ó½Ã true, ¿À·ù½Ã ÇØ´ç object ·Î focus ÀÌµ¿ÈÄ false ¸¦ return

	var value,pow;
	var aTemp,func,szAlert;
	if (typeof(obj)=='undefined') return true;
	value=obj.value.replace(/^[ ]+/g,'').replace(/[ ]+$/g,'');
	if (value==''&&strNE=='') return true;
	aTemp=(strNE+'##').split('##');
	strNE=aTemp[0];
	func=aTemp[1];
	if (value=='') {
		if (strNE!='') {
			alert(strNE);
			
			selectAll(obj);
			return false;
		}
		selectAll(obj);
		return true;
	}
	if ((szAlert=checkFunc(func,value))!='') {
		alert(szAlert);
		selectAll(obj);
		return false;
	}
	if (typeof(strNN)!='undefined') {
		if (iFloat==0) value=parseInt(obj.value,10);
		else {
			value=parseFloat(obj.value);
			if (!isNaN(value)) {
				pow=Math.pow(10,iFloat);
				value=Math.round(value*pow)/pow;
			}
		}
		if (isNaN(value)) {
			if (strNN!='') alert(strNN);
			selectAll(obj);
			return false;
		}
		if (iFloat!=9) obj.value=value;
		if ((szAlert=checkFunc(func,''+value))!='') {
			alert(szAlert);
			selectAll(obj);
			return false;
		}
		if (obj.value<0) {
			alert('À½¼ö´Â ÀÔ·ÂÇÏ½Ç ¼ö ¾ø½À´Ï´Ù.');
			selectAll(obj);
			return false;
		}
		if (typeof(iMin)!='undefined') {
			if (parseInt(obj.value)<parseInt(iMin)) {
				if (strOF!='') alert(strOF);
				selectAll(obj);
				return false;
			}
		}
		if (typeof(iMax)!='undefined') {
			if (parseInt(obj.value)>parseInt(iMax)) {
				if (strOF!='') alert(strOF);
				selectAll(obj);
				return false;
			}
		}
}
	return true;
}
function retManAge(szJumin1,szJumin2) {

	// ÁÖ¹Î¹øÈ£¸¦ ÅëÇØ ¸¸³ªÀÌ¸¦ °è»êÇÔ
	// szJumin1 - ÁÖ¹Î¹øÈ£ ¾ÕÀÚ¸®
	// szJumin2 - ÁÖ¹Î¹øÈ£ µÞÀÚ¸®
	// return - ¸¸³ªÀÌ

	today		= new Date();
	sysDate		= today.toLocaleString();
	sysYear		= sysDate.slice(6,10);
	sysMonDay	= sysDate.slice(0,2) + sysDate.slice(3,5);

	regYear		= szJumin1.slice(0,2);
	regMonDay	= szJumin1.slice(2,6);
	regSex		= szJumin2.slice(0,1);

	if(regSex=="1" || regSex=="2") regYear="19"+regYear; else regYear = "20"+regYear;

	iAge=parseFloat(sysYear)-parseFloat(regYear)-1;
	iMon=parseFloat(sysMonDay)-parseFloat(regMonDay);

	if(iMon>=0)	iAge=iAge+1;

	return iAge;
}

function checkRegisterNum(regno1,regno2) {

	// ÁÖ¹Î¹øÈ£ À¯È¿¼ºÈ®ÀÎ
	// regno1 - ÁÖ¹Î¹øÈ£ ¾ÕÀÚ¸®
	// regno2 - ÁÖ¹Î¹øÈ£ µÞÀÚ¸®
	// return - true or false

	var i = 0;
 	var curYear;
	var curMonth;
 	var birthYear = 0;//Ãâ»ý¿¬µµ ÀúÀå
	var birthMonth = 0;//Ãâ»ý¿ù ÀúÀå
 	var Sum = 0;
	var Mod = 0;
	var YearIn = 0;
	var MonthIn = 0;
	var DateIn = 0;
	if (regno1.length!=6 || regno2.length!=7)	return false;


		var now = new Date();
		var tyear=now.getYear();
		var tmonth=(now.getMonth()+1);
		var tdate=now.getDate();
		if(tmonth<10) tmonth="0"+tmonth;
		if(tdate<10) tdate="0"+tdate;

	curYear		= now.getYear();
	curMonDay	= tmonth+tdate;

	var regno = regno1 + "-" + regno2;
	for( i=0 ; i < 14 ; i++ )
    {//ÁÖ¹Î¹øÈ£ 14ÀÚ¸®¸¦ ÇÑÀÚ¸®¾¿ Ã¼Å©
    	if(i != 6)
        {//´ë½¬(-)¸¦ Á¦¿ÜÇÑ ¸ðµç ÀÔ·Â°ªÀÌ 0 ~ 9 »çÀÌÀÇ °ªÀÎÁö Ã¼Å©
			if( (regno.charAt(i) <= "0") && (regno.charAt(i) >= "9") )	return false;
		}
	}

	birthYear	= regno1.slice(0,2);
	birthMonDay	= regno1.slice(2,6);

	if( regno.charAt(7) == '3' || regno.charAt(7) == '4') birthYear = "20" + birthYear;
	else
	{
		birthYear = "19" + birthYear;

		for( i = 0 ; i < 13 ; i++ )
   		{
			if( i == 0)			YearIn+=parseInt(regno.charAt(i))*10;
			if( i == 1)			YearIn+=parseInt(regno.charAt(i));
  			if( i == 2)			MonthIn+=parseInt(regno.charAt(i))*10;
  		    if( i == 3)			MonthIn+=parseInt(regno.charAt(i));
			if( i == 4)			DateIn+=parseInt(regno.charAt(i))*10;
			if( i == 5)			DateIn+=parseInt(regno.charAt(i));
			if( i < 6)			Sum+=parseInt(regno.charAt(i))*(i+2);
			if( i > 6 && i < 9 )Sum+=parseInt(regno.charAt(i))*(i+1);
   			if( i > 8)			Sum+=parseInt(regno.charAt(i))*(i-7);
		} //end for

		Mod=11-(Sum%11);

		if((11-(Sum%11))>=10) Mod-=10;
		if( Mod!=parseInt(regno.charAt(13)) ) {return false;}
		if( MonthIn < 1 || MonthIn > 12 || DateIn < 1 || DateIn > 31 ) {return false;}
		if( (MonthIn ==4 || MonthIn == 6 || MonthIn == 9 || MonthIn == 11 ) && DateIn > 30 ) {return false;}
		if( MonthIn ==2 && DateIn > 29 ) {return false;}
	}
	iAge=parseFloat(curYear)-parseFloat(birthYear)-1;
	iMon=parseFloat(curMonDay)-parseFloat(birthMonDay);
	if(iMon>=0)	iAge=iAge+1;
	return iAge;
}
function checkEMail(obj,strNN) {

	// email ÀÇ À¯È¿¼ºÈ®ÀÎ ('@'ÀÌ Æ÷ÇÔµÇ°í 'co.kr','ac.kr','com','net','org' ·Î ³¡³ª´Â °æ¿ì)
	// obj - È®ÀÎÇÒ object
	// strNN - ¿À·ù½Ã Ç¥½ÃÇÒ ¹®ÀÚ¿­
	// return - true or false

	if (typeof(obj)=='undefined') return true;

	var value=obj.value;
	if(!value.length) return true;
	if(value.indexOf('@')==-1) {
		alert(strNN);
		selectAll(obj);
		return false;
	}

	var temp=value.split('.');
    for (var i in temp) {
		if(temp[i]=='com' || temp[i]=='net' || temp[i]=='org')	return true;
		else if((temp[i]=='co'&&temp[++i]=='kr') || (temp[--i]=='ac'&&temp[++i]=='kr'))	return true;
    }
	alert(strNN);
	selectAll(obj);
	return false;
}

function chkMsgLen(obj,msg_len,strLT) {
	// object ÀÇ ±æÀÌÀ¯È¿¼º°Ë»ç
	// obj - °Ë»çÇÒ ´ë»ó
	// msg_len - ÃÖ´ë±æÀÌ
	// strLT - ¿À·ù ³»¿ë
	// return - true or false

	var k;
	var str;
    var disp_str;
	var len;
	var temp;
	var tot_cnt;

	str		=obj.value;
	len		=str.length;
	tot_cnt =0;
    disp_str = "";
    for (k=0;k<len;k++){
        temp=str.charAt(k);
        if (escape(temp).length>4)  {tot_cnt+=2;}
        else						{tot_cnt++;}
        if (tot_cnt<=msg_len) {disp_str=disp_str+temp;}
    }
    if(msg_len<=tot_cnt)
    {
        alert(strLT);
		obj.value=disp_str;
        return false;
    }
    return true;
}
function openpost(URL) {

	// ¿ìÆí¹øÈ£ Á¶È¸Ã¢À» ¶ç¿ò

	var winobj;
	if (URL.indexOf('?')==-1) URL='/section/post/postmain.html?'+URL;
	winobj=window.open(URL,'post','toolbar=no,location=no,directory=no,status=yes,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=600,height=320');
	if (winobj!=null) winobj.focus();
}

function openpostother(URL) {
	var szURL;
	szURL=('&'+(URL.toLowerCase())).replace(/[ ]+/g,'');
	if (szURL.indexOf('&Iparformname=')==-1) URL='Iparformname=SellType&'+URL;
	if (szURL.indexOf('&Iparzipcode1=')==-1) URL='Iparzipcode1=ZipCode1&'+URL;
	if (szURL.indexOf('&Iparzipcode2=')==-1) URL='Iparzipcode2=ZipCode2&'+URL;
	if (szURL.indexOf('&Iparozipcode1=')==-1) URL='Iparozipcode1=OZipCode1&'+URL;
	if (szURL.indexOf('&Iparozipcode2=')==-1) URL='Iparozipcode2=OZipCode2&'+URL;
	if (szURL.indexOf('&Ipardongname=')==-1) URL='Ipardongname=DongName&'+URL;
	if (szURL.indexOf('&Ipardongflag=')==-1) URL='Ipardongflag=DongFlag&'+URL;
	if (szURL.indexOf('&Iparaptname=')==-1) URL='Iparaptname=AptName&'+URL;

	openpost(URL);
}
function getValue(szContent,szName) {
	var iStart,iEnd;
	szName=szName+'=';
	while (1) {
		iEnd=szContent.length;
		iStart=szContent.indexOf(szName);
		if (iStart==-1) return '';
		if (iStart==0||szContent.charAt(iStart-1)==';') break;
		szContent=szContent.substring(iStart+1,iEnd);
	}
	szContent=szContent.substring(iStart,iEnd);
	iEnd=szContent.indexOf(';');
	szContent=szContent.substring(0,iEnd);
	return szContent.split(szName)[1];
}
function makeItem() {
	this.value='';
	return this;
}
function makeArray(n) {
	var i;
	this.length=n;
	for (i=0;i<n;i++) this[i]=new makeItem();
	return this;
}
//----------------------------------------------------------------------------------------------------
function getRowIndex(obj) {
	while (1) {
		if (obj==null) break;
		if (obj.tagName=='TR') break;
		obj=obj.parentElement;
	}
	if (obj==null) return -1;
	return obj.rowIndex;
}
function insertRow(szTableName,iIOffset) {
	var objTBL,objTR,iOff;
	objTBL=document.all[szTableName];
	if (objTBL==null) return null;
	if (typeof(iIOffset)=='undefined') iOffset=0; else iOffset=iIOffset;
	objTR=objTBL.insertRow(objTBL.rows.length-iOffset);
	return objTR;
}
function insertCol(objTR,vclass,valign,vvalue) {
	objTD=objTR.insertCell();
	objTD.className=vclass;
	objTD.align=valign;
	objTD.innerHTML=vvalue;
	return objTD;
}
function addContentRow(szFormName,szFieldName,szContent) {
	var obj;
	obj=document.all[szFormName];
	if (obj==null) return '';
	if (szFieldName!='') obj=obj[szFieldName];
	if (obj==null) return '';
	obj.value+='::'+szContent;
	return obj.value;
}
function addContentCol(szContent,szName,szValue) {
	return szContent+szName+'='+szValue+';';
}
function deleteRow(szTableName,iRow,iIRowPerContent) {
	var iRowPerContent,objTBL,i;
	if (typeof(iIRowPerContent)=='undefined') iRowPerContent=1; else iRowPerContent=iIRowPerContent;
	objTBL=document.all[szTableName];
	if (objTBL==null) return 0;
	for (i=0;i<iRowPerContent;i++) objTBL.deleteRow(iRow);
	return i;
}
function deleteContentRow(szFormName,szFieldName,iIndex) {
	var obj,i,aszContent,szContent,szReturn;
	obj=document.all[szFormName];
	if (obj==null) return '';
	if (szFieldName!='') obj=obj[szFieldName];
	if (obj==null) return '';

	szReturn='';

	if (iIndex<0) return szReturn;
	aszContent=obj.value.split('::');
	for (i=1,szContent='';i<aszContent.length;i++)
		if (i-1!=iIndex) szContent+=('::'+aszContent[i]); else szReturn=aszContent[i];
	obj.value=szContent;

	return szReturn;
}
function deleteContentHit(objElement,szTableName,szFormName,szFieldName,iIHeadings,iIRowPerContent) {
	var iRowPerContent,iHeadings,iRow;
	if (typeof(iIRowPerContent)=='undefined') iRowPerContent=1; else iRowPerContent=iIRowPerContent;
	if (typeof(iIHeadings)=='undefined') iHeadings=0; else iHeadings=iIHeadings;

	iRow=getRowIndex(objElement);
	if (iRow==-1) return '';

	deleteRow(szTableName,iRow,iRowPerContent);
	return deleteContentRow(szFormName,szFieldName,(iRow-iHeadings)/iRowPerContent);
}

function OpenWin(file) { 
  var url='/serve/html/detail.html?code='+file; 
  window.open(url,'detail','width=620,height=430');
}

function OpenWin2(file) { 
  var url='/serve/html/detail02.html?code='+file; 
  window.open(url,'detail','width=620,height=430');
}

function MakeWin(file,URL,WIDTH, HEIGHT) { 
  var url=URL+'?code='+file;
  var scale = 'width='+WIDTH+', height='+HEIGHT;   
  window.open(url,'detail',scale);
}

function deleteContentHas(szName,szValue,szTableName,szFormName,szFieldName,iIHeadings,iIRowPerContent) {
	var iRowPerContent,iHeadings,iRow,iDeleted;
	iDeleted=0;
	if (typeof(iIRowPerContent)=='undefined') iRowPerContent=1; else iRowPerContent=iIRowPerContent;
	if (typeof(iIHeadings)=='undefined') iHeadings=0; else iHeadings=iIHeadings;

	var obj,aszTemp,i,szTemp;
	szTemp='';
	obj=document.all[szFormName];
	if (obj==null) return '';
	if (szFieldName!='') obj=obj[szFieldName];
	if (obj==null) return '';
	aszTemp=obj.value.split('::');
	for (i=1;i<aszTemp.length;i++) {
		if (getValue(aszTemp[i],szName)==''+szValue) {
			iRow=(i-1-iDeleted)*iRowPerContent+iHeadings;
			deleteRow(szTableName,iRow,iRowPerContent);
			szTemp=szTemp+'::'+deleteContentRow(szFormName,szFieldName,(iRow-iHeadings)/iRowPerContent);
		}
	}
	return szTemp;
}

// Æ¯¼ö¹®ÀÚ ÀÔ·Â°ÅºÎ ½ÃÀÛ
var mikExp = /[$\\@\\\#%\^\&\*\(\)\[\]\+\_\{\}\`\~\=\|]/;
function dodacheck(val) {
	var strPass = val.value;
	var strLength = strPass.length;
	var lchar = val.value.charAt((strLength) - 1);
	if(lchar.search(mikExp) != -1) {
		var tst = val.value.substring(0, (strLength) - 1);
		val.value = tst;
	}
}
// Æ¯¼ö¹®ÀÚ ÀÔ·Â°ÅºÎ ³¡
//----------------------------------------------------------------------------------------------------




/* n_left.html°¡ È£ÃâÇÏ´Â ·Î±×ÀÎÇÔ¼ö */
function goSubmit(){
	var f=document.formlogin;
	var f2=document.temp;

	if(f2.textfield.value == ""){
			 alert("ID ¸¦ ÀÔ·ÂÇÏ¼¼¿ä.");
			 f2.textfield.focus();
			return;
	}
	if( f2.textfield2.value == ""){
			 alert("PASSWORD ¸¦ ÀÔ·ÂÇÏ¼¼¿ä.");
			 f2.textfield2.focus();
			return;
	}

	saveid(document.temp);
	
	f.USER.value = f2.textfield.value;
	f.PASSWORD.value = f2.textfield2.value;	
	f.action = 'https://membership.chosun.com/siteminderagent/forms/login.fcc';
	f.submit();
}


/* ·Î±×ÀÎ ÇÔ¼ö */
function goLoginForm(){
	location.replace('https://golf.chosun.com/member/login.html?Itargetpage=&SID=');
}


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_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_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];}
}

function MM_swapImage_fortopmenu() { //v3.0
  MM_swapImgRestore();
  var i,j=0,x,a=MM_swapImage_fortopmenu.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];}
}

function MM_showHideLayers() { //v6.0

  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}

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;
}


// ¼³¹®Á¶»ç s ÇüÅÂ 
function add_s(count){
	var addFrm=document.poll_insFrm;
	var ischk=false;	
	
	for (i = 0; i < count; i++) {			
		if( eval("addFrm.user_answer["+i+"].checked") == true){
			ischk=true;
			break;
		}	
	}
	
	if( !ischk ){
		alert("Ç×¸ñÀ» ¼±ÅÃÇØ ÁÖ¼¼¿ä");
		return;
	}
	
	addFrm.submit();
}

// ¼³¹®Á¶»ç m ÇüÅÂ
function add_m(count){
	var addFrm=document.poll_insFrm;
	var ischk=false;	
	
	for (i = 1; i < count; i++) {
		alert(eval("addFrm.user_answer"+i+".checked"));
		if( eval("addFrm.user_answer"+i+".checked") == true){
			ischk=true;
			break;
		}	
	}
	
	if( !ischk ){
		alert("Ç×¸ñÀ» ¼±ÅÃÇØ ÁÖ¼¼¿ä");
		return;
	}
	
	addFrm.submit();
}


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 CH_photo(obj){

	if( obj == "1" ){
	    photolist1.style.display = 'block';
	    photolist2.style.display = 'none';	
		photolist3.style.display = 'none';
		photolist4.style.display = 'none';
	    document.photoimg01.src = "/images/new_index/pga_on.gif";
	    document.photoimg02.src = "/images/new_index/lpga_off.gif";	  
	    document.photoimg03.src = "/images/new_index/kpga_off.gif";
	    document.photoimg04.src = "/images/new_index/klpga_off.gif";
	}else if( obj == "2" ){
		photolist1.style.display = 'none';
	    photolist2.style.display = 'block';
		photolist3.style.display = 'none';
		photolist4.style.display = 'none';
	    document.photoimg01.src = "/images/new_index/pga_off.gif";
	    document.photoimg02.src = "/images/new_index/lpga_on.gif";	  
	    document.photoimg03.src = "/images/new_index/kpga_off.gif";
	    document.photoimg04.src = "/images/new_index/klpga_off.gif";
	}else if( obj == "3" ){
	    photolist1.style.display = 'none';
	    photolist2.style.display = 'none';
		photolist3.style.display = 'block';
		photolist4.style.display = 'none';
	    document.photoimg01.src = "/images/new_index/pga_off.gif";
	    document.photoimg02.src = "/images/new_index/lpga_off.gif";	  
	    document.photoimg03.src = "/images/new_index/kpga_on.gif";
	    document.photoimg04.src = "/images/new_index/klpga_off.gif";
	}else if( obj == "4" ){
	    photolist1.style.display = 'none';
	    photolist2.style.display = 'none';
		photolist3.style.display = 'none';
		photolist4.style.display = 'block';
	    document.photoimg01.src = "/images/new_index/pga_off.gif";
	    document.photoimg02.src = "/images/new_index/lpga_off.gif";	  
	    document.photoimg03.src = "/images/new_index/kpga_off.gif";
	    document.photoimg04.src = "/images/new_index/klpga_on.gif";
	}
}

//¸ÞÀÎÆäÀÌÁö¿¡¼­ searchºÎºÐ
function goSearch(){
	document.totalSearchFrm.submit();	
}


// ¿ëÇ°°¡ÀÌµå Start 
function vbar(o) {
	o.style.backgroundImage="url(\"images/01_booking/01_sub_menu_bg_r.gif\")";
	o.style.fontWeight="bolder";
}

function hbar(o) {
	o.style.backgroundImage="url(\"images/01_booking/01_sub_menu_bg.gif\")";
	o.style.fontWeight="normal";
}
// ¿ëÇ°°¡ÀÌµå End


//Å¬¸¯ÇßÀ» °æ¿ì ±ÛÀÚ ¾ø¾îÁö´Â °Í
function setTextLogin( val, str )
{
		if (val.value == str )
		{
			val.value = "";
			val.focus();
			return;
		}
}

/* ¾ÆÀÌµð ÀÚµ¿ÀÔ·ÂºÎºÐ Start */
function setCookie_id (name, value, expires) {
  document.cookie = name + "=" + escape (value) +
    "; path=/; expires=" + expires.toGMTString();
}

function getCookie_id(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 saveid(form) {
  var expdate = new Date();
  // ±âº»ÀûÀ¸·Î 30ÀÏµ¿¾È ±â¾ïÇÏ°Ô ÇÔ
  if (form.checksaveid.checked) {
    expdate.setTime(expdate.getTime() + 1000 * 3600 * 24 * 30); // 30ÀÏ
	} else {
    expdate.setTime(expdate.getTime() - 1); // ÄíÅ° »èÁ¦Á¶°Ç
	}
	setCookie_id('savedid', form.textfield.value, expdate)
	//document.cookie = 'saveid=' +escape(form.textfield.value)+ '; path=/; expires=' +expdate+ '; domain=.golfchosun.com;'

}

function getid(form) {
  //form.checksaveid.checked = ((form.textfield.value = getCookie("saveid")) != "");
	var id = getCookie_id("savedid");

	if(id!=null && ""!=id) {
		form.textfield.value = id;  //°ªÀ» ³Ö¾îÁÖ°í
		form.checksaveid.checked = true;  //¾ÆÀÌµðÀúÀå Ã¼Å©¹Ú½º¸¦ Ã¼Å©ÇØÁÖ°í
		form.textfield2.focus();  // Æ÷Ä¿½º¸¦ ÆÐ½º¿öµå ÀÔ·Â¿¡ ÁØ´Ù.
	}
}

/* ¾ÆÀÌµð ÀÚµ¿ÀÔ·ÂºÎºÐ End */


/* Áñ°ÜÃ£±â ½ºÅ©¸³Æ® */
function bookmark(){
	window.external.AddFavorite('http://golf.chosun.com/', '´ç½ÅÀÇ ¶ó¿îµå ÆÄÆ®³Ê, °ñÇÁÁ¶¼±!')
}

function setCookie(name,value) {
	document.cookie = name + "=" + escape( value ) + "; path=/;"
}

/* ÆË¾÷ */
function setCookie( name, value, expiredays ) { 
	var todayDate = new Date(); 
	todayDate.setDate( todayDate.getDate() + expiredays ); 
	document.cookie = name + "=" + escape( value ) + "; path=/; expires=" + todayDate.toGMTString() + ";" 
} 

function getCookie( name ) { 
	var nameOfCookie = name + "="; 
	var x = 0; 
	while ( x <= document.cookie.length ) { 
			var y = (x+nameOfCookie.length); 
			if ( document.cookie.substring( x, y ) == nameOfCookie ) { 
				if ( (endOfCookie=document.cookie.indexOf( ";", y )) == -1 ) 
					endOfCookie = document.cookie.length; 
				return unescape( document.cookie.substring( y, endOfCookie ) ); 
			} 
			x = document.cookie.indexOf( " ", x ) + 1; 
			if ( x == 0 ) 
				break; 
	} 
	return ""; 
}

// TV / °¶·¯¸® / ¸ð¹ÙÀÏ
function tv_show(opt) {
	var img_src = new Array ("/images/new_index/tab_tv_on.gif", "/images/new_index/tab_photo_on.gif", "/images/new_index/tab_mobile_on.gif");
	document.getElementById('tv_1').style.display = "none";
	document.getElementById('tv_2').style.display = "none";
	document.getElementById('tv_3').style.display = "none";

	document.getElementById('tv_img_1').src = "/images/new_index/tab_tv_off.gif";
	document.getElementById('tv_img_2').src = "/images/new_index/tab_photo_off.gif";
	document.getElementById('tv_img_3').src = "/images/new_index/tab_mobile_off.gif";
	document.getElementById('tv_'+opt).style.display = "block";
	document.getElementById('tv_img_'+opt).src = img_src[opt-1];
}

// Æ÷Åä / ´ëÈ¸ / °´¿ø in °¶·¯¸®
function CH_top10(obj){
	if( obj == "1" ){
		woodtop10.style.visibility='visible';	
		irontop10.style.visibility='hidden';	
		irontop.style.visibility='hidden';
		document.top10img1.src = "/images/index/main/main_photo_n_icon_1.gif";
		document.top10img2.src = "/images/index/main/main_photo_n_icon_2_2.gif";	 
		document.top10img3.src = "/images/index/main/main_photo_n_icon_3_3.gif";	
	} else if( obj == "2" ){
		woodtop10.style.visibility='hidden';	
		irontop10.style.visibility='visible';	
		irontop.style.visibility='hidden';
		document.top10img1.src = "/images/index/main/main_photo_n_icon_1_1.gif";
		document.top10img2.src = "/images/index/main/main_photo_n_icon_2.gif";	 
		document.top10img3.src = "/images/index/main/main_photo_n_icon_3_3.gif";	
	} else if( obj == "3" ){
		woodtop10.style.visibility='hidden';	
		irontop10.style.visibility='hidden';
		irontop.style.visibility='visible';	
		document.top10img1.src = "/images/index/main/main_photo_n_icon_1_1.gif";
		document.top10img2.src = "/images/index/main/main_photo_n_icon_2_2.gif";	 
		document.top10img3.src = "/images/index/main/main_photo_n_icon_3.gif";	
	}
}

function sponge_show(opt) {
	var img_src = new Array("/images/new_index/ttt_01_on.gif", "/images/new_index/ttt_02_on.gif");
	document.getElementById('sponge_1').style.display = "none";
	document.getElementById('sponge_2').style.display = "none";

	document.getElementById('sponge_img_1').src = "/images/new_index/ttt_01_off.gif";
	document.getElementById('sponge_img_2').src = "/images/new_index/ttt_02_off.gif";
	document.getElementById('sponge_'+opt).style.display = "block";
	document.getElementById('sponge_img_'+opt).src = img_src[opt-1];
}

function news_show(opt) {
	var img_src = new Array("/images/new_index/news_b01_on.gif", "/images/new_index/news_b02_on.gif", "/images/new_index/news_b03_on.gif", "/images/new_index/news_b04_on.gif");
	document.getElementById('news_1').style.display = "none";
	document.getElementById('news_2').style.display = "none";
	document.getElementById('news_3').style.display = "none";
	document.getElementById('news_4').style.display = "none";

	document.getElementById('news_img_1').src = "/images/new_index/news_b01_off.gif";
	document.getElementById('news_img_2').src = "/images/new_index/news_b02_off.gif";
	document.getElementById('news_img_3').src = "/images/new_index/news_b03_off.gif";
	document.getElementById('news_img_4').src = "/images/new_index/news_b04_off.gif";
	document.getElementById('news_'+opt).style.display = "block";
	document.getElementById('news_img_'+opt).src = img_src[opt-1];
}

function score_show(opt) {
	var img_src = new Array("/images/new_index/tt_score_on.gif", "/images/new_index/tt_poll_on.gif", "/images/new_index/tt_gear_on.gif");
	document.getElementById('score_1').style.display = "none";
	document.getElementById('score_2').style.display = "none";
	document.getElementById('score_3').style.display = "none";
	document.getElementById('score_img_1').src = "/images/new_index/tt_score_off.gif";
	document.getElementById('score_img_2').src = "/images/new_index/tt_poll_off.gif";
	document.getElementById('score_img_3').src = "/images/new_index/tt_gear_off.gif";

	document.getElementById('score_'+opt).style.display = "block";
	document.getElementById('score_img_'+opt).src = img_src[opt-1]
}