function is_hangul(s){
	var len = s.length;
	for (var i = 0; i < len; i++) {if (s.charCodeAt(i) != 32 && (s.charCodeAt(i) < 44032 || s.charCodeAt(i) > 55203)){return false;}}
	return true;
}

function is_numeric(s) {var isNum = "0123456789,"; return is_resultchar(s, isNum);}
function is_area(s) {var isNum = "0123456789."; return is_resultchar(s, isNum);}
function is_floor(s) {var isNum = "0123456789-"; return is_resultchar(s, isNum);}
function is_space(s){if(s.search(/\s/) != -1){return true;} else {return false;}}
function is_resultchar(s, c){for (var i=0; i<s.length; i++) {if (c.indexOf(s.charAt(i))<0) return false;} return true;}
function is_textcut(s, c){var text = ""; for( var i = 0; i < c; i++ ) {text += s.charAt(i);} return text;}
function is_result(s, c){
	var ftext = '';
	for (var i=0; i<s.length; i++) {
		if (c!=s.charAt(i)) ftext += s.charAt(i);
	}
	return ftext;
}

function blank_trim(a){ 
	var search = 0;
	while ( a.charAt(search) == " ") {search = search + 1;} 
	a = a.substring(search, (a.length)) ;
	search = a.length - 1;
	while (a.charAt(search) ==" "){search = search - 1;} 
	return a.substring(0, search + 1);
}

function print_flash(s,d,w,h){
	var fcode = "";
	fcode  = "<object type=\"application/x-shockwave-flash\" ";
	fcode +=		"classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" ";
	fcode +=		"codebase=\"http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0\" ";
	fcode +=		"width=\""+w+"\" height=\""+h+"\" id=\""+d+"\">";
	fcode += "<param name=\"movie\" value=\""+s+"\" />";
	fcode += "<param name=\"quality\" value=\"high\" />";
	//fcode += "<param name=\"bgcolor\" value=\"#ffffff\" />";
	fcode += "<param name=\"wmode\" value=\"transparent\" />";
	fcode += "<param name=\"menu\" value=\"false\" />";
	fcode += "<param name=\"allowScriptAccess\" value=\"always\" />";
	fcode += "<param name=\"swliveconnect\" value=\"true\" />";
	fcode += "<embed src=\""+s+"\" quality=\"high\" "
	//code +=        "bgcolor=\"#ffffff\" "
	fcode +=		"wmode=\"transparent\" "
	fcode +=		"menu=\"false\" width=\""+w+"\" height=\""+h+"\" "
	fcode +=		"type=\"application/x-shockwave-flash\" "
	fcode +=		"pluginspage=\"http://www.macromedia.com/go/getflashplayer\"> "
	fcode += "</embed>"
	fcode += "</object>"

    return fcode;
}

function print_flash_ssl(s,d,w,h){
	var fcode = "";
	fcode  = "<object type=\"application/x-shockwave-flash\" ";
	fcode +=		"classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" ";
	fcode +=		"codebase=\"https://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0\" ";
	fcode +=		"width=\""+w+"\" height=\""+h+"\" id=\""+d+"\">";
	fcode += "<param name=\"movie\" value=\""+s+"\" />";
	fcode += "<param name=\"quality\" value=\"high\" />";
	//fcode += "<param name=\"bgcolor\" value=\"#ffffff\" />";
	fcode += "<param name=\"wmode\" value=\"transparent\" />";
	fcode += "<param name=\"menu\" value=\"false\" />";
	fcode += "<param name=\"allowScriptAccess\" value=\"always\" />";
	fcode += "<param name=\"swliveconnect\" value=\"true\" />";
	fcode += "<embed src=\""+s+"\" quality=\"high\" "
	//code +=        "bgcolor=\"#ffffff\" "
	fcode +=		"wmode=\"transparent\" "
	fcode +=		"menu=\"false\" width=\""+w+"\" height=\""+h+"\" "
	fcode +=		"type=\"application/x-shockwave-flash\" "
	fcode +=		"pluginspage=\"https://www.macromedia.com/go/getflashplayer\"> "
	fcode += "</embed>"
	fcode += "</object>"

    return fcode;
}

function winOpen_center(sURL, sWindowName, w, h, sScroll) {
	  // È­¸é Áß¾ÓÀ¸·Î Popup ¶ç¿ì±â.. ½ºÅ©·Ñ¹Ù´Â ¿É¼Ç..
	  // ex)
	  //      openWin("test.asp", "winTest", 400, 300);     ¢Ñ ½ºÅ©·Ñ¹Ù ¾øÀ½
	  //      openWin("test.asp", "winTest", 400, 300, "yes");  ¢Ñ ½ºÅ©·Ñ¹Ù ÀÖÀ½
	  //      openWin("test.asp", "winTest", 400, 300, "auto"); ¢Ñ ½ºÅ©·Ñ¹Ù ÀÚµ¿

	  var x = (screen.width - w) / 2;
	  var y = (screen.height - h) / 2;

	  if (sScroll==null) sScroll = "no";

	  var sOption = "";
	  sOption = sOption + "toolbar=no, channelmode=no, location=no, directories=no, resizable=no, menubar=no";
	  sOption = sOption + ", scrollbars=" + sScroll + ", left=" + x + ", top=" + y + ", width=" + w + ", height=" + h;

	  var win = window.open(sURL, sWindowName, sOption);
	  return win;
}

function window_resize(sWidth, sHeight) {

	// ½ºÅ©·Ñ ¾ø¾Ö±â
	document.body.style.overflow='hidden';

	var clintAgent = navigator.userAgent;
	var foxHeight = 80;
	var ieHeight = 60;
	var ie7Height = 80;
	var ie8Height = 90;

	if ( clintAgent.indexOf("MSIE") != -1 )	// IE ÀÏ °æ¿ì
	{
		var res = isIE7();
		if( isIE7() ) {	window.resizeTo(sWidth, sHeight + ie7Height); }
		else if( isIE8() ) { window.resizeTo(sWidth, sHeight + ie8Height); }
		else { window.resizeTo(sWidth, sHeight + ieHeight); }
	}
	else	// IE °¡ ¾Æ´Ò °æ¿ì
	{
		window.resizeTo(sWidth, sHeight + foxHeight);
	}
}

function round_table(objID) {
   var obj = document.getElementById(objID);
   var Parent, objTmp, Table, TBody, TR, TD;
   var bdcolor, bgcolor, Space;
   var trIDX, tdIDX, MAX;
   var styleWidth, styleHeight;

   Parent = obj.parentNode;
   objTmp = document.createElement('span');
   Parent.insertBefore(objTmp, obj);
   Parent.removeChild(obj);

   bdcolor = obj.getAttribute('rborder');
   bgcolor = obj.getAttribute('rbgcolor');
   radius = parseInt(obj.getAttribute('radius'));
   if (radius == null || radius < 1) radius = 1;
   else if (radius > 6) radius = 6;

   MAX = radius * 2 + 1;

   Table = document.createElement('table');
   TBody = document.createElement('tbody');

   Table.cellSpacing = 0;
   Table.cellPadding = 0;

   for (trIDX=0; trIDX < MAX; trIDX++) {
          TR = document.createElement('tr');
          Space = Math.abs(trIDX - parseInt(radius));
          for (tdIDX=0; tdIDX < MAX; tdIDX++) {
                 TD = document.createElement('td');
                 
                 styleWidth = '1px'; styleHeight = '1px';
                 if (tdIDX == 0 || tdIDX == MAX - 1) styleHeight = null;
                 else if (trIDX == 0 || trIDX == MAX - 1) styleWidth = null;
                 else if (radius > 2) {
                        if (Math.abs(tdIDX - radius) == 1) styleWidth = '2px';
                        if (Math.abs(trIDX - radius) == 1) styleHeight = '2px';
                 }

                 if (styleWidth != null) TD.style.width = styleWidth;
                 if (styleHeight != null) TD.style.height = styleHeight;

                 if (Space == tdIDX || Space == MAX - tdIDX - 1) TD.style.backgroundColor = bdcolor;
                 else if (tdIDX > Space && Space < MAX - tdIDX - 1)  TD.style.backgroundColor = bgcolor;
                 
                 if (Space == 0 && tdIDX == radius) TD.appendChild(obj);
                 TR.appendChild(TD);
          }
          TBody.appendChild(TR);
   }
   Table.appendChild(TBody);
   Parent.insertBefore(Table, objTmp);
}

var xml_key = "52f116f7fbd158fdef9ba143534999e2";
