if (typeof(COMMON_JS) == 'undefined') { // ÇÑ¹ø¸¸ ½ÇÇà
    var COMMON_JS = true;

    // Àü¿ª º¯¼ö
    var errmsg = "";
    var errfld;

    // ÇÊµå °Ë»ç
    function check_field(fld, msg) 
    {
        if ((fld.value = trim(fld.value)) == "") 			   
            error_field(fld, msg);
        else
            clear_field(fld);
        return;
    }

    // ÇÊµå ¿À·ù Ç¥½Ã
    function error_field(fld, msg) 
    {
        if (msg != "")
            errmsg += msg + "\n";
        if (!errfld) errfld = fld;
        fld.style.background = "#BDDEF7";
    }

    // ÇÊµå¸¦ ±ú²ýÇÏ°Ô
    function clear_field(fld) 
    {
        fld.style.background = "#FFFFFF";
    }

    function trim(s)
    {
        var t = "";
        var from_pos = to_pos = 0;

        for (i=0; i<s.length; i++)
        {
            if (s.charAt(i) == ' ')
                continue;
            else 
            {
                from_pos = i;
                break;
            }
        }

        for (i=s.length; i>=0; i--)
        {
            if (s.charAt(i-1) == ' ')
                continue;
            else 
            {
                to_pos = i;
                break;
            }
        }	

        t = s.substring(from_pos, to_pos);
        //				alert(from_pos + ',' + to_pos + ',' + t+'.');
        return t;
    }

    // ÀÚ¹Ù½ºÅ©¸³Æ®·Î PHPÀÇ number_format Èä³»¸¦ ³¿
    // ¼ýÀÚ¿¡ , ¸¦ Ãâ·Â
    function number_format(data) 
    {
        
        var tmp = '';
        var number = '';
        var cutlen = 3;
        var comma = ',';
        var i;
       
        len = data.length;
        mod = (len % cutlen);
        k = cutlen - mod;
        for (i=0; i<data.length; i++) 
        {
            number = number + data.charAt(i);
            
            if (i < data.length - 1) 
            {
                k++;
                if ((k % cutlen) == 0) 
                {
                    number = number + comma;
                    k = 0;
                }
            }
        }

        return number;
    }

    // »õ Ã¢
    function popup_window(url, winname, opt)
    {
        window.open(url, winname, opt);
    }


    // Æû¸ÞÀÏ Ã¢
    function popup_formmail(url)
    {
        opt = 'scrollbars=yes,width=417,height=385,top=10,left=20';
        popup_window(url, "wformmail", opt);
    }

    // , ¸¦ ¾ø¾Ø´Ù.
    function no_comma(data)
    {
        var tmp = '';
        var comma = ',';
        var i;

        for (i=0; i<data.length; i++)
        {
            if (data.charAt(i) != comma)
                tmp += data.charAt(i);
        }
        return tmp;
    }

    // »èÁ¦ °Ë»ç È®ÀÎ
    function del(href) 
    {
        if(confirm("ÇÑ¹ø »èÁ¦ÇÑ ÀÚ·á´Â º¹±¸ÇÒ ¹æ¹ýÀÌ ¾ø½À´Ï´Ù.\n\nÁ¤¸» »èÁ¦ÇÏ½Ã°Ú½À´Ï±î?")) 
            document.location.href = href;
    }

    // ÄíÅ° ÀÔ·Â
    function set_cookie(name, value, expirehours, domain) 
    {
        var today = new Date();
        today.setTime(today.getTime() + (60*60*1000*expirehours));
        document.cookie = name + "=" + escape( value ) + "; path=/; expires=" + today.toGMTString() + ";";
        if (domain) {
            document.cookie += "domain=" + domain + ";";
        }
    }

    // ÄíÅ° ¾òÀ½
    function get_cookie(name) 
    {
        var find_sw = false;
        var start, end;
        var i = 0;

        for (i=0; i<= document.cookie.length; i++)
        {
            start = i;
            end = start + name.length;

            if(document.cookie.substring(start, end) == name) 
            {
                find_sw = true
                break
            }
        }

        if (find_sw == true) 
        {
            start = end + 1;
            end = document.cookie.indexOf(";", start);

            if(end < start)
                end = document.cookie.length;

            return document.cookie.substring(start, end);
        }
        return "";
    }

    // ÄíÅ° Áö¿ò
    function delete_cookie(name) 
    {
        var today = new Date();

        today.setTime(today.getTime() - 1);
        var value = get_cookie(name);
        if(value != "")
            document.cookie = name + "=" + value + "; path=/; expires=" + today.toGMTString();
    }

    // ÀÌ¹ÌÁöÀÇ Å©±â¿¡ µû¶ó »õÃ¢ÀÇ Å©±â°¡ º¯°æµË´Ï´Ù.
    // zzzz´Ô²²¼­ ¾Ë·ÁÁÖ¼Ì½À´Ï´Ù. 2005/04/12
    function image_window(img)
    {
        var w = img.tmp_width; 
        var h = img.tmp_height; 
        var winl = (screen.width-w)/2; 
        var wint = (screen.height-h)/3; 

        if (w >= screen.width) { 
            winl = 0; 
            h = (parseInt)(w * (h / w)); 
        } 

        if (h >= screen.height) { 
            wint = 0; 
            w = (parseInt)(h * (w / h)); 
        } 

        var js_url = "<script language='JavaScript1.2'> \n"; 
            js_url += "<!-- \n"; 
            js_url += "var ie=document.all; \n"; 
            js_url += "var nn6=document.getElementById&&!document.all; \n"; 
            js_url += "var isdrag=false; \n"; 
            js_url += "var x,y; \n"; 
            js_url += "var dobj; \n"; 
            js_url += "function movemouse(e) \n"; 
            js_url += "{ \n"; 
            js_url += "  if (isdrag) \n"; 
            js_url += "  { \n"; 
            js_url += "    dobj.style.left = nn6 ? tx + e.clientX - x : tx + event.clientX - x; \n"; 
            js_url += "    dobj.style.top  = nn6 ? ty + e.clientY - y : ty + event.clientY - y; \n"; 
            js_url += "    return false; \n"; 
            js_url += "  } \n"; 
            js_url += "} \n"; 
            js_url += "function selectmouse(e) \n"; 
            js_url += "{ \n"; 
            js_url += "  var fobj      = nn6 ? e.target : event.srcElement; \n"; 
            js_url += "  var topelement = nn6 ? 'HTML' : 'BODY'; \n"; 
            js_url += "  while (fobj.tagName != topelement && fobj.className != 'dragme') \n"; 
            js_url += "  { \n"; 
            js_url += "    fobj = nn6 ? fobj.parentNode : fobj.parentElement; \n"; 
            js_url += "  } \n"; 
            js_url += "  if (fobj.className=='dragme') \n"; 
            js_url += "  { \n"; 
            js_url += "    isdrag = true; \n"; 
            js_url += "    dobj = fobj; \n"; 
            js_url += "    tx = parseInt(dobj.style.left+0); \n"; 
            js_url += "    ty = parseInt(dobj.style.top+0); \n"; 
            js_url += "    x = nn6 ? e.clientX : event.clientX; \n"; 
            js_url += "    y = nn6 ? e.clientY : event.clientY; \n"; 
            js_url += "    document.onmousemove=movemouse; \n"; 
            js_url += "    return false; \n"; 
            js_url += "  } \n"; 
            js_url += "} \n"; 
            js_url += "document.onmousedown=selectmouse; \n"; 
            js_url += "document.onmouseup=new Function('isdrag=false'); \n"; 
            js_url += "//--> \n"; 
            js_url += "</"+"script> \n"; 

        var settings;

        if (g4_is_gecko) {
            settings  ='width='+(w+10)+','; 
            settings +='height='+(h+10)+','; 
        } else {
            settings  ='width='+w+','; 
            settings +='height='+h+','; 
        }
        settings +='top='+wint+','; 
        settings +='left='+winl+','; 
        settings +='scrollbars=yes,';   //ssh yes·Î ¹Ù²Þ
        settings +='resizable=yes,'; 
        settings +='status=no'; 


        win=window.open("","image_window",settings); 
        win.document.open(); 
        win.document.write ("<html><head> \n<meta http-equiv='imagetoolbar' CONTENT='no'> \n<meta http-equiv='content-type' content='text/html; charset="+g4_charset+"'>\n"); 
        var size = "ÀÌ¹ÌÁö »çÀÌÁî : "+w+" x "+h;
        win.document.write ("<title>"+size+"</title> \n"); 
        if(w >= screen.width || h >= screen.height) { 
            win.document.write (js_url); 
            var click = "ondblclick='window.close();' style='cursor:move' title=' "+size+" \n\n ÀÌ¹ÌÁö »çÀÌÁî°¡ È­¸éº¸´Ù Å®´Ï´Ù. \n ¿ÞÂÊ ¹öÆ°À» Å¬¸¯ÇÑ ÈÄ ¸¶¿ì½º¸¦ ¿òÁ÷¿©¼­ º¸¼¼¿ä. \n\n ´õºí Å¬¸¯ÇÏ¸é ´ÝÇô¿ä. '"; 
        } 
        else 
            var click = "onclick='window.close();' style='cursor:pointer' title=' "+size+" \n\n Å¬¸¯ÇÏ¸é ´ÝÇô¿ä. '"; 
        win.document.write ("<style>.dragme{position:relative;}</style> \n"); 
        win.document.write ("</head> \n\n"); 
        win.document.write ("<body leftmargin=0 topmargin=0 bgcolor=#dddddd style='cursor:arrow;'> \n"); 
        win.document.write ("<table width=100% height=100% cellpadding=0 cellspacing=0><tr><td align=center valign=middle><img src='"+img.src+"' width='"+w+"' height='"+h+"' border=0 class='dragme' "+click+"></td></tr></table>");
        win.document.write ("</body></html>"); 
        win.document.close(); 

        if(parseInt(navigator.appVersion) >= 4){win.window.focus();} 
    }

    // a ÅÂ±×¿¡¼­ onclick ÀÌº¥Æ®¸¦ »ç¿ëÇÏÁö ¾Ê±â À§ÇØ
    function win_open(url, name, option)
    {
        var popup = window.open(url, name, option);
        popup.focus();
    }

    // ¿ìÆí¹øÈ£ Ã¢
    function win_zip(frm_name, frm_zip1, frm_zip2, frm_addr1, frm_addr2)
    {
        url = g4_path + "/" + g4_bbs + "/zip.php?frm_name="+frm_name+"&frm_zip1="+frm_zip1+"&frm_zip2="+frm_zip2+"&frm_addr1="+frm_addr1+"&frm_addr2="+frm_addr2;
        win_open(url, "winZip", "left=50,top=50,width=616,height=460,scrollbars=1");
    }

    // ÂÊÁö Ã¢
    function win_memo(url)
    {
        if (!url)
            url = g4_path + "/" + g4_bbs + "/memo.php";
        win_open(url, "winMemo", "left=50,top=50,width=616,height=460,scrollbars=1");
    }

    // È¸¿ø¸®½ºÆ® Ã¢
    function win_member(url)
    {
        if (!url)
            url = g4_path + "/" + g4_bbs + "/member_list.php";
        win_open(url, "winMemo", "left=50,top=50,width=700,height=650,scrollbars=1");
    }

    // Æ÷ÀÎÆ® Ã¢
    function win_point(url)
    {
        win_open(g4_path + "/" + g4_bbs + "/point.php", "winPoint", "left=20, top=20, width=616, height=635, scrollbars=1");
    }

    // ½ºÅ©·¦ Ã¢
    function win_scrap(url)
    {
        if (!url)
            url = g4_path + "/" + g4_bbs + "/scrap.php";
        win_open(url, "scrap", "left=20, top=20, width=616, height=500, scrollbars=1");
    }

    // ÆÐ½º¿öµå ºÐ½Ç Ã¢
    function win_password_forget()
    {
        win_open(g4_path + "/" + g4_bbs + "/password_forget.php", 'winPasswordForget', 'left=50, top=50, width=616, height=500, scrollbars=1');
    }

    // ÄÚ¸àÆ® Ã¢
    function win_comment(url)
    {
        win_open(url, "winComment", "left=50, top=50, width=800, height=600, scrollbars=1");
    }

    // Æû¸ÞÀÏ Ã¢
    function win_formmail(mb_id, name, email)
    {
		if (g4_charset.toLowerCase() == 'euc-kr')
	        win_open(g4_path+"/" + g4_bbs + "/formmail.php?mb_id="+mb_id+"&name="+name+"&email="+email, "winFormmail", "left=50, top=50, width=600, height=480, scrollbars=0");
		else
	        win_open(g4_path+"/" + g4_bbs + "/formmail.php?mb_id="+mb_id+"&name="+encodeURIComponent(name)+"&email="+email, "winFormmail", "left=50, top=50, width=600, height=480, scrollbars=0");
    }

    // ´Þ·Â Ã¢
    function win_calendar(fld, cur_date, delimiter, opt)
    {
        if (!opt)
            opt = "left=50, top=50, width=240, height=230, scrollbars=0,status=0,resizable=0";
        win_open(g4_path+"/" + g4_bbs + "/calendar.php?fld="+fld+"&cur_date="+cur_date+"&delimiter="+delimiter, "winCalendar", opt);
    }

    // ¼³¹®Á¶»ç Ã¢
    function win_poll(url)
    {
        if (!url)
            url = "";
        win_open(url, "winPoll", "left=50, top=50, width=616, height=500, scrollbars=1");
    }

    // ÀÚ±â¼Ò°³ Ã¢
    function win_profile(mb_id)
    {
        win_open(g4_path+"/" + g4_bbs + "/profile.php?mb_id="+mb_id, 'winProfile', 'left=50,top=50,width=616,height=500,scrollbars=1');
    }

    var last_id = null;
    function menu(id)
    {
        if (id != last_id)
        {
            if (last_id != null)
                document.getElementById(last_id).style.display = "none";
            document.getElementById(id).style.display = "block";
            last_id = id;
        }
        else
        {
            document.getElementById(id).style.display = "none";
            last_id = null;
        }
    }

    function textarea_decrease(id, row)
    {
        if (document.getElementById(id).rows - row > 0)
            document.getElementById(id).rows -= row;
    }

    function textarea_original(id, row)
    {
        document.getElementById(id).rows = row;
    }

    function textarea_increase(id, row)
    {
        document.getElementById(id).rows += row;
    }

    // ±Û¼ýÀÚ °Ë»ç
    function check_byte(content, target)
    {
        var i = 0;
        var cnt = 0;
        var ch = '';
        var cont = document.getElementById(content).value;

        for (i=0; i<cont.length; i++) {
            ch = cont.charAt(i);
            if (escape(ch).length > 4) {
                cnt += 2;
            } else {
                cnt += 1;
            }
        }
        // ¼ýÀÚ¸¦ Ãâ·Â
        document.getElementById(target).innerHTML = cnt;

        return cnt;
    }

    // ºê¶ó¿ìÀú¿¡¼­ ¿ÀºêÁ§Æ®ÀÇ ¿ÞÂÊ ÁÂÇ¥
    function get_left_pos(obj)
    {
        var parentObj = null;
        var clientObj = obj;
        //var left = obj.offsetLeft + document.body.clientLeft;
        var left = obj.offsetLeft;

        while((parentObj=clientObj.offsetParent) != null)
        {
            left = left + parentObj.offsetLeft;
            clientObj = parentObj;
        }

        return left;
    }

    // ºê¶ó¿ìÀú¿¡¼­ ¿ÀºêÁ§Æ®ÀÇ »ó´Ü ÁÂÇ¥
    function get_top_pos(obj)
    {
        var parentObj = null;
        var clientObj = obj;
        //var top = obj.offsetTop + document.body.clientTop;
        var top = obj.offsetTop;

        while((parentObj=clientObj.offsetParent) != null)
        {
            top = top + parentObj.offsetTop;
            clientObj = parentObj;
        }

        return top;
    }

    function flash_movie(src, ids, width, height, wmode)
    {
        var wh = "";
        if (parseInt(width) && parseInt(height)) 
            wh = " width='"+width+"' height='"+height+"' ";
        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' "+wh+" id="+ids+"><param name=wmode value="+wmode+"><param name=movie value="+src+"><param name=quality value=high><embed src="+src+" quality=high wmode="+wmode+" type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?p1_prod_version=shockwaveflash' "+wh+"></embed></object>";
    }

    function obj_movie(src, ids, width, height, autostart)
    {
        var wh = "";
        if (parseInt(width) && parseInt(height)) 
            wh = " width='"+width+"' height='"+height+"' ";
        if (!autostart) autostart = false;
        return "<embed src='"+src+"' "+wh+" autostart='"+autostart+"'></embed>";
    }

    function doc_write(cont)
    {
        document.write(cont);
    }
    /////////////////////////////////////////////ssh³»°¡Ãß°¡
function bt(id,after)
{
eval(id+'.filters.blendTrans.stop();');
eval(id+'.filters.blendTrans.Apply();');
eval(id+'.src="'+after+'";');
eval(id+'.filters.blendTrans.Play();');
}


function openwins(ids,targets,w,h,left,top,sets,mode){ //»õÃ¢¿­±â
  var wint = (screen.height-h)/2;
  var winl = (screen.width-w)/2;
if (mode=="top"){wint=0;}

if (mode=="fix"){
wint=top;
winl=left;
}
  Win = window.open(ids,targets, sets +',width='+w+',height='+h+',top='+wint+',left='+winl);

if (Win == null) {
alert("À©µµ¿ì XP»ç¿ëÀÚ´Â ÆË¾÷Ã¢À» Çã¿ëÇØ ÁÖ¼Å¾ßÇÕ´Ï´Ù.\n\nÈ­¸é ¸ÇÀ§¿¡ [ÆË¾÷ÀÌ Â÷´ÜµÇ¾ú½À´Ï´Ù. ÆË¾÷ ¶Ç´Â Ãß°¡ ¿É¼ÇÀ» º¸·Á¸é ¿©±â¸¦ Å¬¸¯ÇÏ½Ê½Ã¿À] ¹®ÀåÀ» º¸¼¼¿ä. \n\n±× ºÎºÐÀ» Å¬¸¯ÇØ¼­ ÆË¾÷Çã¿ëÀ» ÇØÁÖ½Ã¸é µË´Ï´Ù ");
return;
}

 }

////////////////////////´Þ·Â½ºÅ©¸³Æ®///////////////////////

        /*
        * ¡¡¡¡¡¡¡¡G calendar v0.5
        * (°øÈÞÀÏ ¹× ±¹°æÀÏ Ã¼Å©±â´É¾øÀ½)
        *
        *¡¡¡¡¡¡By Çàº¹ÇÑ°í´Ï(gonom9@empal.com)
        */

        var action_global = ""; //actionÀÇ Àü¿ªº¯¼ö
        var now = new Date();
        var now_year = now.getYear();
        var now_month = now.getMonth()+1;
        var now_day = now.getDate();


        function calendar(action){
                cal(now_year,now_month,now_day,action);
        }

        function cal(year, month, day, action){

        var i, j, day_num=1;
        var last_week, month_link="";
        var calDate = new Date(year, month-1, day_num);
        var checkDate = new Date();
        var date_array = new Array(6);
        for(i=0;i<6;i++) date_array[i] = new Array("","","","","","","");

        //½ºÅ©¸³Æ® ÃßÃâ ¹× º¯È¯, ³»¿ëÀÌ ¾øÀ¸¸é ¸¶Áö¸· action »ç¿ë
        if(action == ""){
                script = action_global;
        }else{
                var script = action;
                var action_mode = action.substring(0,3);
                if(action_mode.toLowerCase()=="url") script = "document.location.href='"+action.substring(4,action.length)+"'";
                action_global = script;
        }

        for(j=0;j<6;j++){
                for(i=0;i<7;i++){
                        if(j==0 && i==0)i = calDate.getDay();
                        date_array[j][i]=day_num+"";
                        day_num++;

                        //ÇØ´ç ³¯Â¥°ª¿¡ ´ëÇÑ À¯È¿¼º °Ë»ç
                        checkDate.setFullYear(year, month-1, day_num);
                        if(checkDate.getDate() != day_num) break;
                }
                if(checkDate.getDate() != day_num) break;
        }
        last_week = (date_array[5][0])?6:5;

        outStr = "<table bgcolor=#CCCCCC width=160 height=160 border=0 cellpadding=0 cellspacing=0 style='border:1 solid black'><tr><td>\n";
        outStr += "<table width=100% height=100% border=0 cellpadding=0 cellspacing=1 style='border:1 solid black'>\n";
        outStr += "<col width=20 align=center></col><col width=20 align=center></col><col width=20 align=center></col><col width=20 align=center></col> <col width=20 align=center></col><col width=20 align=center></col><col width=20 align=center></col>\n";
        outStr += "<tr><td class=calendar style='color:red'>S<td class=calendar>M<td class=calendar>T<td class=calendar>W<td  class=calendar>T<td class=calendar>F<td class=calendar style='color:blue'>S</tr>\n";

        for(j=0;j<last_week;j++){
                outStr += "<tr>";
                for(i=0;i<7;i++){

                        //½ºÅ©¸³Æ® ÀÚ·áº¯È¯
                        if(date_array[j][i]!=""){
                                action_script = script.replace("{y}", year);
                                action_script = action_script.replace("{m}",(month < 10)?"0"+month:month);
                                action_script = action_script.replace("{d}", (date_array[j][i]<10)?"0"+date_array[j][i]:date_array[j][i]);
                        }
                        else action_script = "";
                        today=date_array[j][i];

                        //¿À´ÃÀÌ¸é ÁøÇÏ°Ô
                        if(now_year==year && now_month==month && now_day==today) today="<b>"+today+"</b>";

                        //³¯Â¥º°·Î ½ºÅ©¸³Æ® Ãâ·Â
                        if(i==0){ outStr += "<td class=calendar style='color:red;cursor:hand' onMouseover=this.style.backgroundColor='#FFEEEE' onMouseout=this.style.backgroundColor='' onClick=\""+action_script+"\">"+today+"</td>"; continue; }
                        if(i==6){ outStr += "<td class=calendar style='color:blue;cursor:hand' onMouseover=this.style.backgroundColor='#EEEEFF' onMouseout=this.style.backgroundColor='' onClick=\""+action_script+"\">"+today+"</td>"; continue; }

                        outStr += "<td class=calendar style='cursor:hand' onMouseover=this.style.backgroundColor='#EEEEEE' onMouseout=this.style.backgroundColor='' onClick=\""+action_script+"\">"+today+"</td>";
                }
                outStr += "</tr>\n";
        }

        outStr += "</table></td></tr></table>";



        month_link = (month > 1)? "<a onClick=\"cal("+year+","+(month-1)+","+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢·</a> <font color=black>"+month:"<a onClick=\"cal("+(year-1)+",12,"+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢·</a> <font color=black>"+month;
        month_link += (month < 12)? "</font> <a onClick=\"cal("+year+","+(month+1)+","+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢¹</a>":"</font> <a onClick=\"cal("+(year+1)+",1,"+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢¹</a>";

        //HTML ´ëÀÔ
        document.all.G_cal_body.innerHTML = outStr;
        document.all.G_cal_year.innerHTML = "<a onClick=\"cal("+(year-1)+","+month+","+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢·</a> <font color=black>"+year+"</font> <a onClick=\"cal("+(year+1)+","+month+","+day+",'')\" style='text-decoration:none; color:#909090; cursor:hand'>¢¹</a>";
        document.all.G_cal_month.innerHTML = month_link;
}

function onoff_Gcal(){
        document.all.G_cal.style.top = event.clientY+window.document.body.scrollTop-35;
        document.all.G_cal.style.left = event.clientX+window.document.body.scrollLeft+5;
        document.all.G_cal.style.visibility = (document.all.G_cal.style.visibility=="hidden")?"":"hidden";
}


document.writeln("<style>td.calendar{font-size:8pt; font-family:tahoma;color:black; background-color:white}</style>");
document.writeln(""
+"<div id=G_cal style='width=160;position:absolute;visibility:hidden'>"
+"<table bgcolor=#EEEEEE width=160 height=25 border=0 cellpadding=3 cellspacing=0 style='border:1 solid black'>"
+" <tr><td align=center style='font-size:8pt; font-family:tahoma' Onclick=onoff_Gcal();>"
+" <span id=G_cal_year></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span id=G_cal_month></span>"
+"&nbsp;&nbsp;&nbsp;´Ý±â</td></tr>"
+"</table>"
+"<div id=G_cal_body style='width:160'>"
+"</div></div>");
////////////////////////´Þ·Â½ºÅ©¸³Æ®///////////////////////


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_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_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 bgcolorChange(Obj,Color)
{
	Obj.backgroundColor = Color;
}

function select_copy_ssh1(sw){////ssh06-04-12 list¿¡¼­ ÀÏ°ýÃ³¸®
    var f = document.fboardlist;
    str = "½ÂÀÎ or Ãë¼Ò";

    var sub_win = window.open("", "move", "left=50, top=50, width=396, height=550, scrollbars=1");
    f.sw.value = sw;
    f.target = "move";
    f.action = "./ssh_yn_process.php";
    f.submit();
}


function select_copy_ssh2(bo_table,sw){ ////ssh06-04-12view¿¡¼­ °³º°Ã³¸®
    var sub_win = window.open("./ssh_yn_process.php?bo_table="+bo_table+"&sw="+sw, "move", "left=400, top=50, width=50, height=50, scrollbars=1");
}


/*
function setPng24(obj) {
    obj.width=obj.height=1;
    obj.className=obj.className.replace(/\bpng24\b/i,'');
    obj.style.filter =
    "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+ obj.src +"',sizingMethod='image');"
    obj.src='';
    return '';
}
*/



function resizeFrame(name){   //¾ÆÀÌÇÁ·¹ÀÓ ÀÚµ¿Å©±âÁ¶Àý
       var oBody = document.body;
        var oFrame = parent.document.all(name);
        var min_height = 100; //iframeÀÇ ÃÖ¼Ò³ôÀÌ(³Ê¹« ÀÛ¾ÆÁö´Â °É ¸·±âÀ§ÇÔ, ÇÈ¼¿´ÜÀ§, ÆíÁý°¡´É)
        var min_width = 100; //iframeÀÇ ÃÖ¼Ò³Êºñ
        var i_height = oBody.scrollHeight + (oBody.offsetHeight-oBody.clientHeight);
        var i_width = oBody.scrollWidth + (oBody.offsetWidth-oBody.clientWidth);
        if(i_height < min_height) i_height = min_height;
        if(i_width < min_width) i_width = min_width;
        oFrame.style.height = i_height;
        oFrame.style.width = i_width;
        parent.scrollTo(1,1); //ºÎ¸ð¹®¼­ÀÇ ½ºÅ©·Ñ À§Ä¡¸¦ 1, 1·Î ¿Å±ä´Ù.(¿À°¨µµ´ÔÀÌ ÁöÀûÇØÁÖ¼Ì¾î¿ä~^^)
}


//----------------À¯È¿³¯Â¥Ã¼Å©
  function from_date(value1,value2,value3) {
fm=document.fwrite;
  var pyear  = "0";
  var pmonth= "0";
  var pday  = "0";
  var daysOfMonth = new Array(31,28,31,30,31,30,31,31,30,31,30,31);
   var pyy = 0;
   var pmm = 0;
   var daysOfmm;
pyy = eval("fm."+ value1+".selectedIndex");
pyear = eval("fm."+ value1+".options[pyy].value");
pmm = eval("fm."+ value2+".selectedIndex");
pmonth = eval("fm."+ value2+".options[pmm].value");
dds = eval("fm."+ value3);
    if(pmonth == 2 && ( ( (pyear%4)==0 && (pyear%100)!= 0  ) || (pyear%400) == 0)){
        daysOfmm=29;  }
    else{
       daysOfmm=daysOfMonth[pmonth-1]; }
    if ( daysOfmm>dds.length) {
      for(var i=dds.length; i<daysOfmm; i++){
         var newoption = new Option(i+1);
         dds.options[i] = newoption;  }
   } else  { if (daysOfmm<dds.length)
   { var maxday = dds.length;
      if (maxday>=daysOfmm){
          maxday = daysOfmm-1;
          var ddLength = dds.options.length;
      for(var i=daysOfmm; i<ddLength; i++){
      dds.options[dds.length-1] = null; }
        }
           }
           }
          }
//----------------À¯È¿³¯Â¥Ã¼Å©

if (!g4_is_ie) document.captureEvents(Event.MOUSEMOVE)  //ssh
document.onmousemove = getMouseXY;  //ssh
var tempX = 0;  //ssh
var tempY = 0; //ssh

function help(id, left, top)
{


    menu(id);

    var el_id = document.getElementById(id);

    //submenu = eval(name+".style");
    submenu = el_id.style;
    submenu.left = tempX - 50 + left;
    submenu.top  = tempY + 15 + top;

    selectBoxVisible();

    if (el_id.style.display != 'none')
        selectBoxHidden(id);
}
function getMouseXY(e) {  //ssh
    if (g4_is_ie) { // grab the x-y pos.s if browser is IE
        tempX = event.clientX + document.body.scrollLeft;
        tempY = event.clientY + document.body.scrollTop;
    } else {  // grab the x-y pos.s if browser is NS
        tempX = e.pageX;
        tempY = e.pageY;
    }  

    if (tempX < 0) {tempX = 0;}
    if (tempY < 0) {tempY = 0;}  

    return true;
}


/////////////////////////////////////////////ssh³»°¡Ãß°¡

function base64_decode( data ) {
    // http://kevin.vanzonneveld.net
    // +   original by: Tyler Akins (http://rumkin.com)
    // +   improved by: Thunder.m
    // +      input by: Aman Gupta
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +   bugfixed by: Onno Marsman
    // +   bugfixed by: Pellentesque Malesuada
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +      input by: Brett Zamir (http://brett-zamir.me)
    // +   bugfixed by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // -    depends on: utf8_decode
    // *     example 1: base64_decode('S2V2aW4gdmFuIFpvbm5ldmVsZA==');
    // *     returns 1: 'Kevin van Zonneveld'
 
    // mozilla has this native
    // - but breaks in 2.0.0.12!
    //if (typeof this.window['btoa'] == 'function') {
    //    return btoa(data);
    //}
 
    var b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
    var o1, o2, o3, h1, h2, h3, h4, bits, i = 0, ac = 0, dec = "", tmp_arr = [];
 
    if (!data) {
        return data;
    }
 
    data += '';
 
    do {  // unpack four hexets into three octets using index points in b64
        h1 = b64.indexOf(data.charAt(i++));
        h2 = b64.indexOf(data.charAt(i++));
        h3 = b64.indexOf(data.charAt(i++));
        h4 = b64.indexOf(data.charAt(i++));
 
        bits = h1<<18 | h2<<12 | h3<<6 | h4;
 
        o1 = bits>>16 & 0xff;
        o2 = bits>>8 & 0xff;
        o3 = bits & 0xff;
 
        if (h3 == 64) {
            tmp_arr[ac++] = String.fromCharCode(o1);
        } else if (h4 == 64) {
            tmp_arr[ac++] = String.fromCharCode(o1, o2);
        } else {
            tmp_arr[ac++] = String.fromCharCode(o1, o2, o3);
        }
    } while (i < data.length);
 
    dec = tmp_arr.join('');
    dec = this.utf8_decode(dec);
 
    return dec;
}



function base64_encode( data ) {
    // http://kevin.vanzonneveld.net
    // +   original by: Tyler Akins (http://rumkin.com)
    // +   improved by: Bayron Guevara
    // +   improved by: Thunder.m
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // +   bugfixed by: Pellentesque Malesuada
    // +   improved by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
    // -    depends on: utf8_encode
    // *     example 1: base64_encode('Kevin van Zonneveld');
    // *     returns 1: 'S2V2aW4gdmFuIFpvbm5ldmVsZA=='
 
    // mozilla has this native
    // - but breaks in 2.0.0.12!
    //if (typeof this.window['atob'] == 'function') {
    //    return atob(data);
    //}
        
    var b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
    var o1, o2, o3, h1, h2, h3, h4, bits, i = 0, ac = 0, enc="", tmp_arr = [];
 
    if (!data) {
        return data;
    }
 
    data = this.utf8_encode(data+'');
    
    do { // pack three octets into four hexets
        o1 = data.charCodeAt(i++);
        o2 = data.charCodeAt(i++);
        o3 = data.charCodeAt(i++);
 
        bits = o1<<16 | o2<<8 | o3;
 
        h1 = bits>>18 & 0x3f;
        h2 = bits>>12 & 0x3f;
        h3 = bits>>6 & 0x3f;
        h4 = bits & 0x3f;
 
        // use hexets to index into b64, and append result to encoded string
        tmp_arr[ac++] = b64.charAt(h1) + b64.charAt(h2) + b64.charAt(h3) + b64.charAt(h4);
    } while (i < data.length);
    
    enc = tmp_arr.join('');
    
    switch( data.length % 3 ){
        case 1:
            enc = enc.slice(0, -2) + '==';
        break;
        case 2:
            enc = enc.slice(0, -1) + '=';
        break;
    }
 
    return enc;
}


function setClipBoardText(strValue){  //ssh
 window.clipboardData.setData('Text', strValue); 
 alert("" + strValue +" \n\nÀ§ ³»¿ëÀÌ º¹»çµÇ¾ú½À´Ï´Ù.\n\nCtrl + v Å°¸¦ »ç¿ëÇÏ¿©, ºÙ¿© ³Ö±â¸¦ »ç¿ëÇÏ½Ç ¼ö ÀÖ½À´Ï´Ù."); 
} 


	
}

