function TableTopRound(width, color, borderColor) {
	if (borderColor == null)
	{
		borderColor = color;
	}

	var top_html;

	top_html="<table cellpadding=0 cellspacing=0 border=0 width="+width+">";
	top_html+="<tr height=1><td rowspan=4 width=1></td><td rowspan=3 width=1></td>";
	top_html+="<td rowspan=2 width=1></td><td width=2></td><td bgcolor="+borderColor+"></td>";
	top_html+="<td width=2></td><td rowspan=2 width=1></td><td rowspan=3 width=1></td>";
	top_html+="<td rowspan=4 width=1></td></tr><tr height=1><td bgcolor="+borderColor+"></td>";
	top_html+="<td bgcolor="+color+"></td><td bgcolor="+borderColor+"></td></tr>";
	top_html+="<tr height=1><td bgcolor="+borderColor+"></td><td colspan=3 bgcolor="+color+"></td>";
	top_html+="<td bgcolor="+borderColor+"></td></tr><tr height=2><td bgcolor="+borderColor+"></td>";
	top_html+="<td colspan=5 bgcolor="+color+"></td><td bgcolor="+borderColor+"></td></tr></table>";

	document.write(top_html);
}

function TableBtmRound(width, color, borderColor) {
	if (borderColor == null)
	{
		borderColor = color;
	}

	var bottom_html;

	bottom_html="<table cellpadding=0 cellspacing=0 border=0 width="+width+">";
	bottom_html+="<tr height=2><td rowspan=4 width=1></td><td width=1 bgcolor="+borderColor+"></td><td width=1 bgcolor="+color+"></td>";
	bottom_html+="<td width=2 bgcolor="+color+"></td><td bgcolor="+color+"></td><td width=2 bgcolor="+color+"></td>";
	bottom_html+="<td width=1 bgcolor="+color+"></td><td width=1 bgcolor="+borderColor+"></td><td rowspan=4 width=1></td></tr>";
	bottom_html+="<tr height=1><td rowspan=3></td><td bgcolor="+borderColor+"></td><td colspan=3 bgcolor="+color+"></td>";
	bottom_html+="<td bgcolor="+borderColor+"></td><td rowspan=3></td>  </tr><tr height=1><td rowspan=2></td>";
	bottom_html+="<td bgcolor="+borderColor+"></td><td bgcolor="+color+"></td><td bgcolor="+borderColor+"></td><td rowspan=2></td></tr>";
	bottom_html+="<tr height=1><td></td><td bgcolor="+borderColor+"></td><td></td></tr></table>";

	document.write(bottom_html);
}

function MakeButton(label, width, height, bgColor, txtColor, borderColor, overColor, fontFamily, fontSize, padding)
{
	if (borderColor == null || borderColor == "")
	{
		borderColor = bgColor;
	}

	if (overColor == null || overColor == "")
	{
		overColor = bgColor;
	}

	if (fontFamily == null || fontFamily == "")
	{
		fontFamily = "±¼¸²";
	}

	if (fontSize == null || fontSize == "")
	{
		fontSize = 9;
	}

	if (padding == null || padding == "")
	{
		padding = "3px 0 0 0";
	}

	var innerWidth = width - 2;

	document.write('<span style="vertical-align:top;">');
	document.write('<table align=absmiddle border=0 cellspacing=0 cellpadding=0 width="'+width+'" height="'+height+'" onSelectStart="return false" style="display:inline">');
	document.write('<tr height=1>');
	document.write('<td width="1"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="1"> </td>');
	document.write('</tr>');
	document.write('<tr>');
	document.write('<td width="1" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+bgColor+'" align="center" style="font-family: '+fontFamily+'; font-size:'+fontSize+'pt; cursor:pointer; padding:'+padding+'; color:'+txtColor+'" onMouseOver="this.style.backgroundColor=\''+overColor+'\'; window.status=\''+label+'\';return true" onMouseOut="this.style.backgroundColor=\''+bgColor+'\'; window.status=\'\'" onMouseDown="this.style.backgroundColor=\''+bgColor+'\'" onMouseUp="this.style.backgroundColor=\''+overColor+'\'"><nobr>'+label+'</nobr></td>');
	document.write('<td width="1" bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width="1"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="1"> </td>');
	document.write('</tr>');
	document.write('</table>');
	document.write('</span>');
}

function MakeRoundButton(label, width, height, bgColor, txtColor, borderColor, overColor, fontFamily, fontSize, padding)
{
	if (borderColor == null || borderColor == "")
	{
		borderColor = bgColor;
	}

	if (overColor == null || overColor == "")
	{
		overColor = bgColor;
	}

	if (fontFamily == null || fontFamily == "")
	{
		fontFamily = "±¼¸²";
	}

	if (fontSize == null || fontSize == "")
	{
		fontSize = 9;
	}

	if (padding == null || padding == "")
	{
		padding = "3px 0 0 0";
	}

	var innerWidth = width - 2;
	var innerWidth2 = width - 4;

	document.write('<span style="vertical-align:top;">');
	document.write('<table align=absmiddle border=0 cellspacing=0 cellpadding=0 width="'+width+'" height="'+height+'" onSelectStart="return false" style="display:inline">');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width="'+innerWidth2+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth2+'" bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" colspan=3 bgcolor="'+bgColor+'" align="center" style="font-family: '+fontFamily+'; font-size:'+fontSize+'pt; cursor:pointer; padding:'+padding+'; color:'+txtColor+'" onMouseOver="this.style.backgroundColor=\''+overColor+'\'; this.parentElement.parentElement.rows[1].cells[2].style.backgroundColor=\''+overColor+'\'; this.parentElement.parentElement.rows[3].cells[2].style.backgroundColor=\''+overColor+'\'" onMouseOut="this.style.backgroundColor=\''+bgColor+'\'; this.parentElement.parentElement.rows[1].cells[2].style.backgroundColor=\''+bgColor+'\'; this.parentElement.parentElement.rows[3].cells[2].style.backgroundColor=\''+bgColor+'\'" onMouseDown="this.style.backgroundColor=\''+bgColor+'\'; this.parentElement.parentElement.rows[1].cells[2].style.backgroundColor=\''+bgColor+'\'; this.parentElement.parentElement.rows[3].cells[2].style.backgroundColor=\''+bgColor+'\'" onMouseUp="this.style.backgroundColor=\''+overColor+'\'; this.parentElement.parentElement.rows[1].cells[2].style.backgroundColor=\''+overColor+'\'; this.parentElement.parentElement.rows[3].cells[2].style.backgroundColor=\''+overColor+'\'"><nobr>'+label+'</nobr></td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth2+'" bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width="'+innerWidth2+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('</table>');
	document.write('</span>');
}

function MakeRoundShadowButton(label, width, height, bgColor, txtColor, borderColor, overColor, innerShadow, outerShadow, fontFamily, fontSize, padding)
{
	if (borderColor == null || borderColor == "")
	{
		borderColor = bgColor;
	}

	if (overColor == null || overColor == "")
	{
		overColor = bgColor;
	}

	if (innerShadow == null || innerShadow == "")
	{
		innerShadow = "#F7F7F7";
	}

	if (outerShadow == null || outerShadow == "")
	{
		outerShadow = "#EFEBEF";
	}

	if (fontFamily == null || fontFamily == "")
	{
		fontFamily = "±¼¸²";
	}

	if (fontSize == null || fontSize == "")
	{
		fontSize = 9;
	}

	if (padding == null || padding == "")
	{
		padding = "3px 0 0 2px";
	}

	var innerWidth = width - 4;
	var innerWidth2 = width - 5;
	var innerWidth3 = width - 6;

	document.write('<span style="vertical-align:top;">');
	document.write('<table align=absmiddle border=0 cellspacing=0 cellpadding=0 width="'+width+'" height="'+height+'" onSelectStart="return false" style="display:inline">');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth3+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width="'+innerWidth3+'" bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" colspan=3 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" colspan=3 bgcolor="'+bgColor+'" align="center" style="font-family: '+fontFamily+'; font-size:'+fontSize+'pt; cursor:pointer; padding:'+padding+'; color:'+txtColor+'">'+label+'</td>');
	document.write('<td width=1 bgcolor="'+innerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+bgColor+'"> </td>');
	document.write('<td width="'+innerWidth2+'" colspan=2 bgcolor="'+innerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width="'+innerWidth3+'" bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+outerShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth3+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('</table>');
	document.write('</span>');
}

function Make3dButton(label, width, height, bgColor, txtColor, borderColor, overColor, innerBorder, lightShadow, darkShadow1, darkShadow2, fontFamily, fontSize, padding)
{
	if (borderColor == null || borderColor == "")
	{
		borderColor = bgColor;
	}

	if (overColor == null || overColor == "")
	{
		overColor = bgColor;
	}

	if (innerBorder == null || innerBorder == "")
	{
		innerBorder = "#EDEDED";
	}

	if (lightShadow == null || lightShadow == "")
	{
		lightShadow = "#FFFFFF";
	}

	if (darkShadow1 == null || darkShadow1 == "")
	{
		darkShadow1 = "#DCDCDC";
	}

	if (darkShadow2 == null || darkShadow2 == "")
	{
		darkShadow2 = "#BFBFBF";
	}

	if (fontFamily == null || fontFamily == "")
	{
		fontFamily = "±¼¸²";
	}

	if (fontSize == null || fontSize == "")
	{
		fontSize = 9;
	}

	if (padding == null || padding == "")
	{
		padding = "1px 0 0 0";
	}

	var innerWidth = width - 8;

	document.write('<span style="vertical-align:top;">');
	document.write('<table align=absmiddle border=0 cellspacing=0 cellpadding=0 width="'+width+'" height="'+height+'" onSelectStart="return false" style="display:inline">');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+innerBorder+'""> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+bgColor+'" align="center" style="font-family: '+fontFamily+'; font-size:'+fontSize+'pt; cursor:pointer; padding:'+padding+'; color:'+txtColor+'" onMouseOver="this.style.backgroundColor=\''+overColor+'\'" onMouseOut="this.style.backgroundColor=\''+bgColor+'\'" onMouseDown="this.style.backgroundColor=\''+bgColor+'\'" onMouseUp="this.style.backgroundColor=\''+overColor+'\'"><span style=" position:relative; top:1">'+label+'</span></td>');
	document.write('<td width=1 bgcolor="'+darkShadow1+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+lightShadow+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow1+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+darkShadow1+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow1+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+darkShadow2+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+innerBorder+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('<tr height=1>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width="'+innerWidth+'" bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1 bgcolor="'+borderColor+'"> </td>');
	document.write('<td width=1> </td>');
	document.write('<td width=1> </td>');
	document.write('</tr>');
	document.write('</table>');
	document.write('</span>');
}

/*
¹öÆ°Å¸ÀÔ 2 - ¸¹ÀÌ ±¼·ÁÁø Æò¸é ¹öÆ°

bgColor : #FFEBCD
txtColor : #C04001
borderColor : #FFA927
overColor : #FECA7C
(*'¡ª') Áø¿µ ´ÔÀÇ ¸»:
¹öÆ°Å¸ÀÔ 3 - ¸¹ÀÌ ±¼·ÁÁø ÀÔÃ¼(±×¸²ÀÚ) ¹öÆ°

bgColor : #FFFFFF
txtColor : #7D0000
borderColor : #A74E2F
innerShadow : #E9D6CF
outerShadow : #D09E8D
*/

function MakeBtn_purple(label, width, height, fontFamily, fontSize, padding)
{
	MakeButton(label, width, height, "#D4D7F8", "#003399", "#9999CC", "#F291F2", fontFamily, fontSize, padding);
}

function MakeBtn_lorange(label, width, height, fontFamily, fontSize, padding)
{
	MakeButton(label, width, height, "#FFEBCD", "#C04001", "#FFA927", "#FECA7C", fontFamily, fontSize, padding);
}

function MakeRdBtn_purple(label, width, height, fontFamily, fontSize, padding)
{
	MakeRoundButton(label, width, height, "#D4D7F8", "#003399", "#9999CC", "#F291F2", fontFamily, fontSize, padding);
}

function MakeRdBtn_lorange(label, width, height, fontFamily, fontSize, padding)
{
	MakeRoundButton(label, width, height, "#FFEBCD", "#C04001", "#FFA927", "#FECA7C", fontFamily, fontSize, padding);
}

function MakeSdBtn_purple(label, width, height, fontFamily, fontSize, padding)
{
	MakeRoundShadowButton(label, width, height, "#FFFFFF", "#003399", "#9999CC", "#F291F2", "#E6E6E6", "#CCC2CC", fontFamily, fontSize, padding);
}

function MakeSdBtn_gray(label, width, height, fontFamily, fontSize, padding)
{
	MakeRoundShadowButton(label, width, height, "#FFFFFF", "#555555", "#A1A1A1", "#F291F2", "#E6E6E6", "#CCC2CC", fontFamily, fontSize, padding);
}

function MakeSdBtn_lorange(label, width, height, fontFamily, fontSize, padding)
{
	MakeRoundShadowButton(label, width, height, "#FFFFFF", "#7D0000", "#A74E2F", null, "#E9D6CF", "#D09E8D", fontFamily, fontSize, padding);
}

function Make3dBtn_gray(label, width, height, fontFamily, fontSize, padding)
{
	Make3dButton(label, width, height, "#EDEDED", "#000000", "#5D5D5D", "#FAFAFA", null, null, null, null, fontFamily, fontSize, padding);
}
