
function Submit_Check()
{

	if(!F.b_subject.value) {
		alert('글 제목을 입력하세요');
		F.b_subject.focus();
		return false;
	}

	if(F.b_name) {
		if(!F.b_name.value) {
			alert('작성자의 성명을 입력하세요');
			F.b_name.focus();
			return false;
		}
	}

	if(F.b_passwd) {
		if(!F.b_passwd.value) {
			alert('패스워드를 입력하세요');
			F.b_passwd.focus();
			return false;
		}
	}

	if(document.getElementById('Editor_iframe')) Editor_submit();

	if(document.getElementById('SmartEditor_Html')) SmartEditor_Submit();

	return true;

}


function Guest_Check(mode)
{

	if(!document.all("DeleteCheckLayer"))  {

		var _DIV	= document.createElement('div');

		_DIV.id		= "DeleteCheckLayer";
		_DIV.style.position	= "absolute";
		_DIV.style.overflow	= "hidden";
		_DIV.style.padding = 1;
		_DIV.style.background = "#3399FF";
		_DIV.style.color = "#ffffff";
		_DIV.style.borderStyle = "solid";
		_DIV.style.borderWidth = 1;
		_DIV.style.borderColor = "#3333CC";
		_DIV.style.filter = "progid:DXImageTransform.Microsoft.dropShadow(Color=999999,offX=3,offY=3,positive=true)";

		document.getElementById('Button').appendChild(_DIV);

	} else {

		var _DIV	= document.getElementById("DeleteCheckLayer");

	}

	var html = "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
	html += "<form action='' method='post' name='F'>";
	html += "<tr height='30'>";
	html += "<td width='30%' align='right'>비밀번호 :&nbsp;</td>";
	html += "<td><input type='hidden' name='MODE' value='"+mode+"'><input name='passwd' type='password' size='10' style='border-style:solid;border-width:1;border-color:green;margin-left:1;'><input type='submit' value='확인' style='border-style:solid;border-width:1;border-color:green;margin-left:1;'><input type='submit' value='닫기' onclick=\"document.getElementById('DeleteCheckLayer').removeNode(true)\" style='border-style:solid;border-width:1;border-color:green;margin-left:1;'></td>";
	html += "</tr>";
	html += "</form>";
	html += "</table>";

	_DIV.innerHTML = html;

	_DIV.style.width = 270;
	_DIV.style.height = 35;

	_DIV.style.top = document.body.scrollTop + event.clientY - 35;
	_DIV.style.left = event.clientX - 270;

	document.F.passwd.focus();
}
