// ¸Þ´ºÀÌ¹ÌÁö ÇÁ¸®·Îµå ½ÃÀÛ
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.0
	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 && document.getElementById)
		x=document.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];
		}
	}
}

function MM_openBrWindow(theURL,winName,features){window.open(theURL,winName,features);}

function VeiwXCall(strUrl,strCallQuery,strMethod)
{
	var VeiwCallUrl = "";
	var VeiwReDataBuffer = "";
	var VeiwRedata;
	if((strMethod=="GET") || (strMethod=="get"))
		VeiwCallUrl = strUrl+"?"+strCallQuery;
	else
		VeiwCallUrl = strUrl;

	if (window.ActiveXObject)
	{
		try{VeiwRedata=new ActiveXObject("Msxml2.XMLHTTP");}
		catch(e){
			try{VeiwRedata=new ActiveXObject("Microsoft.XMLHTTP");}
			catch(e){
				try{VeiwRedata=new ActiveXObject("window.XMLHttpRequest");}
				catch(e){}
			}
		}
	}
	else if(window.XMLHttpRequest)
	{
		VeiwRedata = new XMLHttpRequest();
		if(VeiwRedata.overrideMimeType){VeiwRedata.overrideMimeType('text/html');}
	}

	VeiwRedata.open(strMethod, VeiwCallUrl, false);
	VeiwRedata.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
	VeiwRedata.onreadystatechange = function(){
		if (VeiwRedata.readyState == 4)
			VeiwReDataBuffer=VeiwRedata.responseText;
	}

	if((strMethod=="GET") || (strMethod=="get"))
		VeiwRedata.send(null);
	else
		VeiwRedata.send(strCallQuery);

	return VeiwReDataBuffer;
	//return CallRedata.responseText;
}


function XCall(CallUrl,CallQuery)
{
	var ReCallUrl = "./"+CallUrl+"?"+CallQuery;
	var CallReDataBuffer = "";
	//var CallRedata = new ActiveXObject("Microsoft.XMLHTTP");

	if (window.ActiveXObject)
	{
		try{
			//Windows IE7
			CallRedata=new ActiveXObject("Msxml2.XMLHTTP");
		}
		catch(e){
			try{
				CallRedata=new ActiveXObject("Microsoft.XMLHTTP");
			}
			catch(e){
				try{
					CallRedata=new ActiveXObject("window.XMLHttpRequest");
					//xmlRequest=new XMLHttpRequest();
				}
				catch(e){}
			}
		}
	}
	else if(window.XMLHttpRequest)
	{
		CallRedata = new XMLHttpRequest();
		if(CallRedata.overrideMimeType){CallRedata.overrideMimeType('text/html');}
	}


	CallRedata.open("POST", ReCallUrl, false);
	CallRedata.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
		CallRedata.onreadystatechange = function(){
			if (CallRedata.readyState == 4){
				CallReDataBuffer=CallRedata.responseText;
			}
		}

	CallRedata.send(null);
	return CallReDataBuffer;
	//return CallRedata.responseText;
}

function MessageLogin(){alert('È¸¿ø Àü¿ë Á¤º¸ÀÔ´Ï´Ù.\n·Î±×ÀÎ ÇØÁÖ½Ã±â ¹Ù¶ø´Ï´Ù.');}
function GeneralMessage(){if (confirm('º» Á¤º¸´Â À¯·á È¸¿ø¿¡°Ô¸¸ Á¦°øµÇ´Â Á¤º¸ÀÔ´Ï´Ù.\nÈ¸¿ø°¡ÀÔ ÇÏ½Ã°Ú½À´Ï±î?')){opener.top.location = "http://www.kyungmaeguide.co.kr/member/member_new/new.asp";}}
function MessageMemberAreaFalse(){alert('È¸¿ø´ÔÀÇ ¼­ºñ½º Áö¿ªÀÌ ¾Æ´Õ´Ï´Ù.\n¼­ºñ½ºÁö¿ªÀ» Ãß°¡ÇÏ½Å ÈÄ ÀÌ¿ëÇÏ½Ã±â ¹Ù¶ø´Ï´Ù.')}
// ¸Þ´ºÀÌ¹ÌÁö ÇÁ¸®·Îµå ³¡

function FlashDis(FlashUrl,FlashWidth,FlashHeight)
{
	document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='https://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0' width='"+FlashWidth+"' height='"+FlashHeight+"'>");
	document.write("<param name='movie' value='"+FlashUrl+"'>");
	document.write("<param name='quality' value='high'>");
	document.write("<embed src='"+FlashUrl+"' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='"+FlashWidth+"' height='"+FlashHeight+"'>");
	document.write("</object>");
}
function ActiveXDis(ActiveXUrl,ActiveXWidth,ActiveXHeight)
{
//	document.write("<embed src='"+ActiveXUrl+"' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'>");
	document.write("<OBJECT classid='clsid:CA8A9780-280D-11CF-A24D-444553540000' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'>");
	document.write("<PARAM name='SRC' value='"+ActiveXUrl+"'>");
	document.write("<embed src='"+ActiveXUrl+"' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'>");
	document.write("</OBJECT>");
//	document.write("<object type='application/pdf' data='"+ActiveXUrl+"' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'> </object>");
}

function ActiveXSub(ActiveXUrl,ActiveXWidth,ActiveXHeight)
{
	document.write("<OBJECT classid='clsid:CA8A9780-280D-11CF-A24D-444553540000' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'>");
	document.write("<PARAM name='SRC' value='"+ActiveXUrl+"'>");
	document.write("<embed src='"+ActiveXUrl+"' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'>");
	document.write("</OBJECT>");
//	document.write("<object type='application/pdf' data='"+ActiveXUrl+"' width='"+ActiveXWidth+"' height='"+ActiveXHeight+"'> </object>");
}

function PrintX(thisPrint)
{
	var initBody = document.body.innerHTML;
	window.onbeforeprint = function(){document.body.innerHTML = document.getElementById(thisPrint).innerHTML;}
	window.onafterprint = function(){document.body.innerHTML = initBody;}
	window.print();
}