<!--

var calendar_html_show_white =	'<form name="CalendarForm" style="margin:0px;">'
+							'<table border="0" cellspacing="1" cellpadding="0" width="150" bgcolor="#777777">'
+							'<tr bgcolor="ffffff"> '
+							'<td bgcolor="ffffff" align="center"> '
+							'<table border="0" cellspacing="0" cellpadding="0" width="150" bgcolor="#eeeeee"> '
+							'<tr height="5"><td nowrap></td></tr> '
+							'<tr height="15"> '
+							'<td align="center" width="50%"> '
+							'<div id="CalendarPrevMonth"><img src="./images/common/ico_prev.gif" width="9" heigh="11"  border="0"></div></td> '
+							'<td align="center" width="" nowrap> '
+							'<select name="cal_year" style="font-famliy:Tahoma;font-size:11px;color:#777777;background-color:#ffffff;"></select> '
+							'<select name="cal_month" style="font-famliy:Tahoma;font-size:11px;color:#777777;background-color:#ffffff;"> '
+							'<option value="0">01</option> '
+							'<option value="1">02</option> '
+							'<option value="2">03</option> '
+							'<option value="3">04</option> '
+							'<option value="4">05</option> '
+							'<option value="5">06</option> '
+							'<option value="6">07</option> '
+							'<option value="7">08</option> '
+							'<option value="8">09</option> '
+							'<option value="9">10</option> '
+							'<option value="10">11</option> '
+							'<option value="11">12</option> '
+							'</select> '
+							'</td> '
+							'<td align="center" width="50%"> '
+							'<div id="CalendarNextMonth"><img src="./images/common/ico_next.gif" width="9" heigh="11" border="0"></div></td></td> '
+							'</tr> '
+							'<tr height="5"><td nowrap></td></tr> '
+							'</table> '


+							'<table border="0" cellspacing="0" cellpadding="0" width="100%" align="center">'
+							'<tr><td height="1"  bgcolor="#333333" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#999999" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#cccccc" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#eeeeee" nowrap></td>'
+							'</table>'


+							'<table border="0" cellspacing="0" cellpadding="0" width="140"> '
+							'<tr align="center" height="20"> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#FF0000;cursor:default;" title="Sunday">S</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Monday">M</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Tuesday">T</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Wednesday">W</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Thursday">T</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Friday">F</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#0000FF;cursor:default;" title="Saturday">S</td> '
+							'</tr> '
+							'<tr> '
+							'<td height="1" colspan="7" bgcolor="black"></td> '
+							'</tr> '
+							'</table> '
+							'<table border="0" cellspacing="0" cellpadding="1" width="140"> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_1_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_2_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_3_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_4_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_5_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_6_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'</table> '
+							'</div> '


+							'<table border="0" cellspacing="0" cellpadding="0" width="100%" align="center">'
+							'<tr><td height="1"  bgcolor="#eeeeee" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#cccccc" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#999999" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#333333" nowrap></td>'
+							'</table>'


+							'<table border="0" cellspacing="1" cellpadding="2" width="150" bgcolor="#eeeeee"> '
+							'<tr> '
+							'<td align="left"  style="font-family:Tahoma;font-size:11px;color:#777777;">'
+							'Today <div id="CalendarToday" style="display:inline;font-family:Tahoma;font-size:9px;color:#777777;" onmouseover="this.style.color=\'#000000\';" onmouseout="this.style.color=\'#777777\';"></div></td>'
+							'<td align="right"  style="font-family:Tahoma;font-size:11px;color:#777777;"><div id="CalendarClose" style="display:inline" style="font-family:Tahoma;font-size:11px;color:#777777;font-weight:bold;" onmouseover="this.style.color=\'#000000\';" onmouseout="this.style.color=\'#777777\';">Close</div></td>'
+							'</tr>'
+							'</table>'
+							'</td>'
+							'</tr>'
+							'</table>'
+							'</form>';


var calendar_html_show_black =	'<form name="CalendarForm" style="margin:0px;">'
+							'<table border="0" cellspacing="1" cellpadding="0" width="150" bgcolor="#333333">'
+							'<tr> '
+							'<td bgcolor="ffffff" align="center"> '
+							'<table border="0" cellspacing="0" cellpadding="0" width="150" bgcolor="#333333"> '
+							'<tr height="5"><td nowrap></td></tr> '
+							'<tr height="15"> '
+							'<td align="center" width="50%"> '
+							'<div id="CalendarPrevMonth"><img src="./images/common/ico_prev.gif" width="9" heigh="11"  border="0"></div></td> '
+							'<td align="center" width="" nowrap> '
+							'<select name="cal_year" style="font-famliy:Tahoma;font-size:11px;color:#ffffff;background-color:#333333;"></select> '
+							'<select name="cal_month" style="font-famliy:Tahoma;font-size:11px;color:#ffffff;background-color:#333333;"> '
+							'<option value="0">01</option> '
+							'<option value="1">02</option> '
+							'<option value="2">03</option> '
+							'<option value="3">04</option> '
+							'<option value="4">05</option> '
+							'<option value="5">06</option> '
+							'<option value="6">07</option> '
+							'<option value="7">08</option> '
+							'<option value="8">09</option> '
+							'<option value="9">10</option> '
+							'<option value="10">11</option> '
+							'<option value="11">12</option> '
+							'</select> '
+							'</td> '
+							'<td align="center" width="50%"> '
+							'<div id="CalendarNextMonth"><img src="./images/common/ico_next.gif" width="9" heigh="11" border="0"></div></td></td> '
+							'</tr> '
+							'<tr height="5"><td nowrap></td></tr> '
+							'</table> '


+							'<table border="0" cellspacing="0" cellpadding="0" width="100%" align="center">'
+							'<tr><td height="1"  bgcolor="#333333" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#999999" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#cccccc" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#eeeeee" nowrap></td>'
+							'</table>'


+							'<table border="0" cellspacing="0" cellpadding="0" width="140"> '
+							'<tr align="center" height="20"> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#FF0000;cursor:default;" title="Sunday">S</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Monday">M</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Tuesday">T</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Wednesday">W</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Thursday">T</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#000000;cursor:default;" title="Friday">F</td> '
+							'<td width="20" style="font-family:Tahoma;font-size:11px;color:#0000FF;cursor:default;" title="Saturday">S</td> '
+							'</tr> '
+							'<tr> '
+							'<td height="1" colspan="7" bgcolor="black"></td> '
+							'</tr> '
+							'</table> '
+							'<table border="0" cellspacing="0" cellpadding="1" width="140"> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_1_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_1_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_2_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_2_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_3_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_3_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_4_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_4_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_5_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_5_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'<tr align="center" height="18"> '
+							'<td width="20"><div id="CalendarDay_6_1" style="font-family:Tahoma;font-size:11px;color:#FF0000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_2" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_3" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_4" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_5" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_6" style="font-family:Tahoma;font-size:11px;color:#000000;"></div></td> '
+							'<td width="20"><div id="CalendarDay_6_7" style="font-family:Tahoma;font-size:11px;color:#0000FF;"></div></td> '
+							'</tr> '
+							'</table> '
+							'</div> '


+							'<table border="0" cellspacing="0" cellpadding="0" width="100%" align="center">'
+							'<tr><td height="1"  bgcolor="#eeeeee" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#cccccc" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#999999" nowrap></td>'
+							'<tr><td height="1"  bgcolor="#333333" nowrap></td>'
+							'</table>'


+							'<table border="0" cellspacing="1" cellpadding="2" width="150" bgcolor="#333333"> '
+							'<tr> '
+							'<td align="left"  style="font-family:Tahoma;font-size:11px;color:#ffffff;">'
+							'Today <div id="CalendarToday" style="display:inline;font-family:Tahoma;font-size:9px;color:#ffffff;" onmouseover="this.style.color=\'#dddddd\';" onmouseout="this.style.color=\'#ffffff\';"></div></td>'
+							'<td align="right"  style="font-family:Tahoma;font-size:11px;color:#ffffff;"><div id="CalendarClose" style="display:inline" style="font-family:Tahoma;font-size:11px;color:#ffffff;font-weight:bold;" onmouseover="this.style.color=\'#dddddd\';" onmouseout="this.style.color=\'#ffffff\';">Close</div></td>'
+							'</tr>'
+							'</table>'
+							'</td>'
+							'</tr>'
+							'</table>'
+							'</form>';

Calendar = function (obj) {
try{
	getID('layerObj_CalendarLayerSHOW').parentNode.removeChild( getID('layerObj_CalendarLayerSHOW') );
} catch(e) { }
try{
    var IE = document.all ? true : false;
    this.avail = (document.getElementById) ? true : false;
    if (!this.avail) return;
    var classObj = this;
    this.obj = obj;
	this.layerObj = document.createElement("SPAN");
	this.layerObj.innerHTML = calendar_html_show_black;
	with(this.layerObj.style){
		position = 'absolute';
		width = '150px';
		height = '250px';
	}
	this.layerObj.id = "layerObj_CalendarLayerSHOW";
	document.body.appendChild(this.layerObj);

    this._setDateSeperator = "-";   // ³¯Â¥ ±¸ºÐÀÚ
    this._setPrevColor = "#CCCCCC"; // ÀÌÀü´Þ ³¯Â¥ »ö
    this._setPrevBackground = "";   // ÀÌÀü´Þ ³¯Â¥ ¹è°æ»ö
    this._setNextColor = "#CCCCCC"; // ´ÙÀ½´Þ ³¯Â¥ »ö
    this._setNextBackground = "";   // ´ÙÀ½´Þ ³¯Â¥ ¹è°æ»ö
    this._setNowBold = true;        // ¼±ÅÃ ³¯Â¥ Bold¿©ºÎ
    this._setNowColor = "#0000FF";     // ¼±ÅÃ ³¯Â¥ »ö
    this._setNowBackground = "";    // ¼±ÅÃ ³¯Â¥ ¹è°æ»ö
    this._setTodayBold = true;      // ¿À´Ã ³¯Â¥ Bold¿©ºÎ
    this._setTodayColor = "#FF0000";    // ¿À´Ã ³¯Â¥ »ö
    this._setTodayBackground = "";  // ¿À´Ã ³¯Â¥ ¹è°æ»ö


    this.calForm = document.forms["CalendarForm"];
    this.calForm.cal_year.onchange = function () {
        classObj.year = parseInt(this[this.selectedIndex].value, 10);
        classObj.setCalendar();
    }
    this.calForm.cal_month.onchange = function () {
        classObj.month = parseInt(this[this.selectedIndex].value, 10);
        classObj.setCalendar();
    }

    if (document.all) {
        document.getElementById("CalendarPrevMonth").style.cursor = "hand";
        document.getElementById("CalendarNextMonth").style.cursor = "hand";
        document.getElementById("CalendarToday").style.cursor     = "hand";
        document.getElementById("CalendarClose").style.cursor     = "hand";
    } else {
        document.getElementById("CalendarPrevMonth").style.cursor = "pointer";
        document.getElementById("CalendarNextMonth").style.cursor = "pointer";
        document.getElementById("CalendarToday").style.cursor     = "pointer";
        document.getElementById("CalendarClose").style.cursor     = "pointer";
    }
    document.getElementById("CalendarPrevMonth").onclick = function () {
        classObj.shiftMonth(-1);
    }
    document.getElementById("CalendarNextMonth").onclick = function () {
        classObj.shiftMonth(+1);
    }
    var d = new Date();
    document.getElementById("CalendarToday").innerHTML = "(" + this.getDateFormat(d.getFullYear(), d.getMonth(), d.getDate()) + ")";
    document.getElementById("CalendarToday").onclick = function () {
        var d = new Date();
        classObj.setDate(d.getFullYear(), d.getMonth(), d.getDate());
        classObj.destroy();
    }
    document.getElementById("CalendarClose").onclick = function () {
        classObj.destroy();
    }

	document.getElementById("CalendarDay_1_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_1"));
    }
    document.getElementById("CalendarDay_1_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_1"));
    }
	document.getElementById("CalendarDay_1_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_2"));
    }
    document.getElementById("CalendarDay_1_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_2"));
    }
	document.getElementById("CalendarDay_1_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_3"));
    }
    document.getElementById("CalendarDay_1_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_3"));
    }
	document.getElementById("CalendarDay_1_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_4"));
    }
    document.getElementById("CalendarDay_1_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_4"));
    }
	document.getElementById("CalendarDay_1_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_5"));
    }
    document.getElementById("CalendarDay_1_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_5"));
    }
	document.getElementById("CalendarDay_1_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_6"));
    }
    document.getElementById("CalendarDay_1_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_6"));
    }
	document.getElementById("CalendarDay_1_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_1_7"));
    }
    document.getElementById("CalendarDay_1_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_1_7"));
    }

	document.getElementById("CalendarDay_2_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_1"));
    }
    document.getElementById("CalendarDay_2_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_1"));
    }
	document.getElementById("CalendarDay_2_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_2"));
    }
    document.getElementById("CalendarDay_2_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_2"));
    }
	document.getElementById("CalendarDay_2_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_3"));
    }
    document.getElementById("CalendarDay_2_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_3"));
    }
	document.getElementById("CalendarDay_2_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_4"));
    }
    document.getElementById("CalendarDay_2_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_4"));
    }
	document.getElementById("CalendarDay_2_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_5"));
    }
    document.getElementById("CalendarDay_2_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_5"));
    }
	document.getElementById("CalendarDay_2_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_6"));
    }
    document.getElementById("CalendarDay_2_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_6"));
    }
	document.getElementById("CalendarDay_2_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_2_7"));
    }
    document.getElementById("CalendarDay_2_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_2_7"));
    }

	document.getElementById("CalendarDay_3_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_1"));
    }
    document.getElementById("CalendarDay_3_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_1"));
    }
	document.getElementById("CalendarDay_3_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_2"));
    }
    document.getElementById("CalendarDay_3_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_2"));
    }
	document.getElementById("CalendarDay_3_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_3"));
    }
    document.getElementById("CalendarDay_3_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_3"));
    }
	document.getElementById("CalendarDay_3_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_4"));
    }
    document.getElementById("CalendarDay_3_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_4"));
    }
	document.getElementById("CalendarDay_3_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_5"));
    }
    document.getElementById("CalendarDay_3_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_5"));
    }
	document.getElementById("CalendarDay_3_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_6"));
    }
    document.getElementById("CalendarDay_3_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_6"));
    }
	document.getElementById("CalendarDay_3_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_3_7"));
    }
    document.getElementById("CalendarDay_3_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_3_7"));
    }

	document.getElementById("CalendarDay_4_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_1"));
    }
    document.getElementById("CalendarDay_4_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_1"));
    }
	document.getElementById("CalendarDay_4_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_2"));
    }
    document.getElementById("CalendarDay_4_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_2"));
    }
	document.getElementById("CalendarDay_4_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_3"));
    }
    document.getElementById("CalendarDay_4_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_3"));
    }
	document.getElementById("CalendarDay_4_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_4"));
    }
    document.getElementById("CalendarDay_4_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_4"));
    }
	document.getElementById("CalendarDay_4_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_5"));
    }
    document.getElementById("CalendarDay_4_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_5"));
    }
	document.getElementById("CalendarDay_4_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_6"));
    }
    document.getElementById("CalendarDay_4_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_6"));
    }
	document.getElementById("CalendarDay_4_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_4_7"));
    }
    document.getElementById("CalendarDay_4_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_4_7"));
    }

	document.getElementById("CalendarDay_5_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_1"));
    }
    document.getElementById("CalendarDay_5_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_1"));
    }
	document.getElementById("CalendarDay_5_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_2"));
    }
    document.getElementById("CalendarDay_5_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_2"));
    }
	document.getElementById("CalendarDay_5_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_3"));
    }
    document.getElementById("CalendarDay_5_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_3"));
    }
	document.getElementById("CalendarDay_5_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_4"));
    }
    document.getElementById("CalendarDay_5_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_4"));
    }
	document.getElementById("CalendarDay_5_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_5"));
    }
    document.getElementById("CalendarDay_5_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_5"));
    }
	document.getElementById("CalendarDay_5_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_6"));
    }
    document.getElementById("CalendarDay_5_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_6"));
    }
	document.getElementById("CalendarDay_5_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_5_7"));
    }
    document.getElementById("CalendarDay_5_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_5_7"));
    }

	document.getElementById("CalendarDay_6_1").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_1"));
    }
    document.getElementById("CalendarDay_6_1").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_1"));
    }
	document.getElementById("CalendarDay_6_2").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_2"));
    }
    document.getElementById("CalendarDay_6_2").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_2"));
    }
	document.getElementById("CalendarDay_6_3").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_3"));
    }
    document.getElementById("CalendarDay_6_3").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_3"));
    }
	document.getElementById("CalendarDay_6_4").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_4"));
    }
    document.getElementById("CalendarDay_6_4").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_4"));
    }
	document.getElementById("CalendarDay_6_5").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_5"));
    }
    document.getElementById("CalendarDay_6_5").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_5"));
    }
	document.getElementById("CalendarDay_6_6").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_6"));
    }
    document.getElementById("CalendarDay_6_6").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_6"));
    }
	document.getElementById("CalendarDay_6_7").onmouseover = function () {
        classObj.overEvent(document.getElementById("CalendarDay_6_7"));
    }
    document.getElementById("CalendarDay_6_7").onmouseout = function () {
        classObj.outEvent(document.getElementById("CalendarDay_6_7"));
    }

    this.show();
}catch(e){}
}

Calendar.prototype.overEvent = function (obj) {
	obj.style.backgroundColor = "#e5e5e5";
}

Calendar.prototype.outEvent = function (obj) {
	obj.style.backgroundColor = "#ffffff";
}

Calendar.prototype.getDateFormat = function (year, month, day) {
    month++;
    if (month.toString().length == 1) month = "0" + month;
    if (day.toString().length == 1)   day = "0" + day;
    return year + this._setDateSeperator + month + this._setDateSeperator + day;
}

Calendar.prototype.shiftMonth = function (val) {
    this.month += val;
    d = new Date(this.year, this.month, this.day);
    this.year  = d.getFullYear();
    this.month = d.getMonth();
    this.day   = d.getDate();
    this.setCalendar();
}

Calendar.prototype.setDate = function (year, month, day) {
    this.obj.value = this.getDateFormat(year, month, day);
}

Calendar.prototype.setCalendar = function () {
    if (this.yearOld != this.year) this.setYear(this.calForm.cal_year);
    this.setMonth(this.calForm.cal_month);

    if (this.yearOld != this.year || this.monthOld != this.month) {
        this.drawCalendar(this.year, this.month, this.day);
    }

    this.yearOld = this.year;
    this.monthOld = this.month;
}

Calendar.prototype.drawCalendar = function (year, month, day) {
    var calDate     = new Date(year, month, 1);
    var calWeekday  = calDate.getDay();
    var calDays     = this.getMonthDays(year, month + 1);
    var calPrevDays = this.getMonthDays(year, month);
    var calDay      = 1;
    var calNextDay  = 1;
    for (var i=0; i<6; i++) {  // loop for month-weeks
        for (var j=0; j<7; j++) {  // loop for week-days
            var dayLayer = eval("document.getElementById('CalendarDay_"+ (i+1) +"_"+ (j+1) +"')");
            if (i==0 && j<calWeekday) {
                this.linkDay(dayLayer, year, month - 1, calPrevDays - (calWeekday - j) + 1, 'prev');
            } else if (calDay > calDays) {
                this.linkDay(dayLayer, year, month + 1, calNextDay, 'next');
                calNextDay++;
            } else {
                this.linkDay(dayLayer, year, month, calDay);
                calDay++;
            }
        }
    }
}

Calendar.prototype.linkDay = function (layer, year, month, day, monthTab) {
    var classObj = this;
    var d = new Date();
    layer.innerHTML = day;
    if (this.yearSet == year && this.monthSet == month && this.daySet == day) { // ¼±ÅÃ³¯Â¥ È¿°ú
        layer.style.fontWeight = (this._setNowBold == true) ? "bold" : "";
        layer.style.color      = (this._setNowColor) ? this._setNowColor : "";
        layer.style.background = (this._setNowBackground) ? this._setNowBackground : "";
    } else if (d.getFullYear() == year && d.getMonth() == month && d.getDate() == day) { // ¿À´Ã³¯Â¥ È¿°ú
        layer.style.fontWeight = (this._setTodayBold == true) ? "bold" : "";
        layer.style.color      = (this._setTodayColor) ? this._setTodayColor : "";
        layer.style.background = (this._setTodayBackground) ? this._setTodayBackground : "";
    } else if (monthTab == 'prev') {   // ÀÌÀü´Þ È¿°ú
        layer.style.fontWeight = "";
        layer.style.color      = (this._setPrevColor) ?  this._setPrevColor : "";;
        layer.style.background = (this._setPrevBackground) ? this._setPrevBackground : "";
    } else if (monthTab == 'next') { // ´ÙÀ½´Þ È¿°ú
        layer.style.fontWeight = "";
        layer.style.color      = (this._setNextColor) ? this._setNextColor: "";
        layer.style.background = (this._setNextBackground) ? this._setNextBackground : "";
    } else {
        layer.style.fontWeight = "";
        layer.style.color      = "";
        layer.style.background = "";
    }
    layer.style.cursor = (document.all) ? "hand" : "pointer";
    layer.onclick = function () {
        var d = new Date(year, month, day);
        classObj.setDate(d.getFullYear(), d.getMonth(), d.getDate());
        classObj.destroy();
    }
}

Calendar.prototype.setYear = function (yearObj) {
    yearObj.options.length = 0;
    for (var i=this.year-5, j=0; i<=this.year+5; i++, j++) {
        yearObj.options[j] = new Option(i , i, false);
        if (i == this.year) yearObj.options[j].selected = true;
    }
}

Calendar.prototype.setMonth = function (monthObj) {
    monthObj.selectedIndex = this.month;
}

Calendar.prototype.show = function () {
	var classObj = this;
    var objTmp = this.obj;
    var layerX = 0;
    var layerY = 0;
    while (objTmp) {
        layerX += objTmp.offsetLeft;
        layerY += objTmp.offsetTop;
        objTmp = objTmp.offsetParent;
    }
    this.layerObj.style.left = layerX;
    this.layerObj.style.top  = layerY + 20;
    this.layerObj.style.display = "block";

    var datePattern = /^([0-9]{4})[\-\.]?([01][0-9])[\-\.]?([0-3][0-9])$/;
    if (datePattern.test(this.obj.value)) {
        datePattern.exec(this.obj.value);
        var d = new Date(parseInt(RegExp.$1, 10), parseInt(RegExp.$2, 10) - 1, parseInt(RegExp.$3, 10));
    } else {
        var d = new Date();
    }
    this.year  = d.getFullYear();
    this.month = d.getMonth();
    this.day   = d.getDate();
    this.yearSet  = this.year;
    this.monthSet = this.month;
    this.daySet   = this.day;
    this.setCalendar();
}

Calendar.prototype.getMonthDays = function (year, month) {
    var d = new Date(year, month, 0);
    return d.getDate();
}

Calendar.prototype.destroy = function () {
    this.layerObj.style.display = "none";
    this.obj = null;
    this.yearOld = null;
    this.monthOld = null;
}
//-->