	//ÀÔ·Â Æû Ã¼Å©
	function bcf(){
		var intNUM = 0;
		if (!document.board.title.value)				{ alert('Á¦¸ñÀ» ÀÔ·ÂÇÏ¼¼¿ä'); 		document.board.title.focus(); 							return; }
		if (document.board.contenttype.value == "0") {
			if (!document.board.content.value)		{ alert("³»¿ëÀ» Àû¾îÁÖ¼¼¿ä!"); 		document.board.content.focus(); 						return; }
		} else {
			document.getElementById("content").value = myeditor.outputBodyHTML();
			if (!document.getElementById("content").value)				{ alert("³»¿ëÀ» Àû¾îÁÖ¼¼¿ä!");										return; }	
		}
		
		var i, strSubTitle = '';
		document.getElementById('subtitle_1').value = document.board.secret.value;
		
		try {
			document.getElementById('subtitle_2').value	= fileUP.document.fileform.upload_files.value;
			document.getElementById('filename').value		= fileUP.document.fileform.upload_file.value;
		} catch(e) {}
			
		try {
			for (i = 1 ; i <= 10 ; i++) {
				strSubTitle = strSubTitle + document.getElementById('subtitle_' + i).value + "//";
			}
		} catch(e) {}

		document.getElementById('subtitle').value = strSubTitle;
		
		document.board.submit();
	}
	
	//Àü´Þ°ª »ý¼º
	function brs(intSeq, intThread, intDepth, intIcon, intFilename, strIDX, strSection, strURL, strCheck){
		if (intSeq =="")		{ intSeq == "" }
		if (intThread =="")		{ intThread == "" }
		if (intDepth =="")		{ intDepth == "" }
		if (intIcon =="")		{ intIcon == "" }
		if (intFilename =="")	{ intFilename == "" }
		if (strIDX =="")		{ strIDX == "" }
		if (strSection =="")		{ strSection == "" }
		if (strURL =="")		{ strURL == "" }
		if (strCheck =="")		{ strCheck == "" }
		
		var div ='';
		var strPWD = document.private.pwd.value;
		
		if (strSection != "delete") {
			div = div + '<form name="board" method="post">';
			div = div + '	<input type="hidden" name="pwd"		value="'+ strPWD +'">';
			div = div + '	<input type="hidden" name="seq"			value="'+ intSeq +'">';
			div = div + '	<input type="hidden" name="thread"		value="'+ intThread +'">';
			div = div + '	<input type="hidden" name="depth"		value="'+ intDepth +'">';
			div = div + '	<input type="hidden" name="icon"		value="'+ intIcon +'">';
			div = div + '	<input type="hidden" name="filename"		value="'+ intFilename +'">';
			div = div + '	<input type="hidden" name="idx"			value="'+ strIDX +'">';
			div = div + '	<input type="hidden" name="section"		value="'+ strSection +'">';
			div = div + '	<input type="hidden" name="url"			value="'+ strURL +'">';
			div = div + '</form>';
			
			eval("formDIV").innerHTML = div;
			document.board.action = strURL
			brfs();
			
		} else {
			if(confirm("ºÎ¸ð±ÛÀ» »èÁ¦½Ã ÇÏÀ§ ´ñ±ÛÀÌ ¸ðµÎ »èÁ¦ µË´Ï´Ù.\n»èÁ¦ÇÏ½Ã°Ú½À´Ï±î?")){
				div = div + '<form name="board" method="post">';
				div = div + '	<input type="hidden" name="pwd"		value="'+ strPWD +'">';
				div = div + '	<input type="hidden" name="seq"			value="'+ intSeq +'">';
				div = div + '	<input type="hidden" name="thread"		value="'+ intThread +'">';
				div = div + '	<input type="hidden" name="depth"		value="'+ intDepth +'">';
				div = div + '	<input type="hidden" name="icon"		value="'+ intIcon +'">';
				div = div + '	<input type="hidden" name="filename"		value="'+ intFilename +'">';
				div = div + '	<input type="hidden" name="idx"			value="'+ strIDX +'">';
				div = div + '	<input type="hidden" name="idxname"		value="'+ strIDX +'">';
				div = div + '	<input type="hidden" name="section"		value="'+ strSection +'">';
				div = div + '	<input type="hidden" name="url"			value="'+ strURL +'">';
				div = div + '</form>';
				
				eval("formDIV").innerHTML = div;
				document.board.action =  '/Board/ProcessModule.asp';
				brfs();
			} else {
				return;
			}
		}
	}
	
	function brss()
	{
		var strSECTION 	= document.private.section.value;
		var intSeq		= "";
		var intThread		= "";
		var intDepth		= "";
		var intIcon		= "";
		var intFilename	= "";
		var strIDX		= "";
		var strSECTION	= "";
		var strURL		= "";
		var strCheck		= "";

		intSeq		= document.private.seq.value;
		strIDX		= document.private.idxname.value;
		strSECTION	= document.private.section.value;
		strURL		= document.private.url.value;
		strCheck		= document.private.check.value;

		if (strSECTION == "insert") {
			intThread		= document.private.thread.value;
			intDepth		= document.private.depth.value;
			intIcon		= document.private.icon.value;
			intFilename	= document.private.filename.value;
		} else {
			if (strCheck == "false"){
				if (!document.private.pwd.value)	{
					alert('ºñ¹Ð¹øÈ£¸¦ ÀÔ·ÂÇÏ¼¼¿ä');
					document.private.pwd.focus();
					return;
				}
			}
		}
		brs(intSeq, intThread, intDepth, intIcon, intFilename, strIDX, strSECTION, strURL, strCheck);
	}
	
	function brfs()
	{
		document.board.submit();
	}

	function bes()
	{
		if (!document.board.email3.value) {
			document.board.email2.value = "";
		} else {
			document.board.email2.value = document.board.email3.value;
		}
	}
	
	function bws()
	{
		if(document.search.searchstring.value.length == 0)	{ alert("°Ë»ö¾î¸¦ ÀÔ·ÂÇÏ¼¼¿ä.");		document.search.searchstring.focus();	return; }
		document.search.submit();
	}
	
	function odiv(intSeq)
	{
		document.getElementById('pwdDIV').style.display='block';
		
		document.private.seq.value = intSeq;
	}

	function ediv(intSeq, strSECTION, strCHECKID)
	{
		document.private.section.value	= strSECTION;
		document.private.seq.value		= intSeq;
		
		if (strCHECKID == "false" && strSECTION != "insert") {
			document.private.pwd.value	= "";
			
			var divHeight	= "";
			var strMSG	= "";
			
			divHeight = calculateOffset(document.getElementById("formDIV"), "offsetTop") - 130;
			
			if (strSECTION == "edit") {
				strMSG = "¼öÁ¤";
			} else {
				strMSG = " »èÁ¦";
			}
			
			document.getElementById('pwdDIV').style.display	= 'block';
			document.getElementById('pwdDIV').style.top		= divHeight;
			
			eval("sectionDIV").innerHTML = strMSG;
		} else {
			brss();
		}
	}
	
	function cdiv(intSeq)
	{
		document.getElementById('pwdDIV').style.display='none';
	}
	
	function bcp() {
		if (!document.private.pwd.value)	{ alert('ºñ¹Ð¹øÈ£¸¦ ÀÔ·ÂÇÏ¼¼¿ä'); 	document.private.pwd.focus(); 	 return; }
		
		document.private.submit();
	}
	
	function calculateOffset(getElement, attr)
	{
		var offset = 0;
		while(getElement) {
			offset += getElement[attr];
			getElement = getElement.offsetParent;
		}
		
		return offset;
	}
	
	function bcb() {
		document.getElementById('btnlist').click();
	}
	
	function rmd(intSEQ) {
		$.getJSON("/Board/AddRecommend.asp", "seq="+ intSEQ, function (returnData, textStatus){
			if(textStatus == 'success') {
				$.each(returnData, function(intIDX, ojbDATA) {
					if (ojbDATA.intRESULT == "0") {
						alert("ÃßÃµÇÏ±â¿¡ ¹®Á¦°¡ ÀÖ½À´Ï´Ù.\n°ü¸®ÀÚ¿¡°Ô ¹®ÀÇÇÏ¼¼¿ä.");
						return;
					} else if (ojbDATA.intRESULT == "1") {
						var intREC_COUNT = parseInt($("#recCOUNT").text()) + 1;
						$("#recCOUNT").text(intREC_COUNT);
						alert("ÃßÃµÇÏ±â°¡ ¿Ï·á µÇ¾ú½À´Ï´Ù.");
					} else if (ojbDATA.intRESULT == "2") {
						alert("ÀÌ¹Ì ÃßÃµÇÏ¿´½À´Ï´Ù.");
					} else if (ojbDATA.intRESULT == "3") {
						alert("·Î±×ÀÎ ÈÄ °¡´ÉÇÕ´Ï´Ù.");
					}
				});
			} else { 
				alert("ÃßÃµÇÏ±â¿¡ ½ÇÆÐÇÏ¿´½À´Ï´Ù.\n°ü¸®ÀÚ¿¡°Ô ¹®ÀÇÇÏ¼¼¿ä.");
				return;
			} 
		});
	}
