/* =================================================================
	setFilter()
	Æ¯¼ö¹®ÀÚ Ã¼Å©
--------------------------------------------------------------------
	nValue		ÀÔ·Â°ª
================================================================= */
function setFilter(nValue) { 
	var strobj = document.getElementById(nValue); 

	re = /[ \{\}\[\]\/?.,;:|\)*~`!^\-_+¦«<>@\#$%&\'\"\\\(\=]/gi; 

	if(re.test(strobj.value)) { 
		alert("Æ¯¼ö¹®ÀÚ´Â ÀÔ·ÂÇÏ½Ç ¼ö ¾ø½À´Ï´Ù."); 
		strobj.value = strobj.value.replace(re,""); 
		strobj.focus(); 
		return; 
	} 
} 

/* =================================================================
	_cmdfocus()
	formobj¿¡ FocusÀÌµ¿
--------------------------------------------------------------------
	formobj
================================================================= */
function _cmdfocus(formobj){
	formobj.focus();
}

/* =================================================================
	syncChkSlangFilter()
	¿å¼³ Ã¼Å©
--------------------------------------------------------------------
	formField	Form Field
	message	Form Field Value
================================================================= */

function syncChkSlangFilter(formField, message) {
	
	//	 -------------------- ¿å¼³ Check  --------------------
	slang = new Array("cunt","shit","fuck","asshole","motherfucker","suck","pussy","cock","sux","dick","bitch","damn","sucker","fucker",
			"°³»õ³¢","°³ÀÚ½Ä","°³½¦ÀÌ","ÀÌ»õ³¢","Àú»õ³¢","±×»õ³¢","¾¾¹ú","½ÃÆÈ","½Ã¹ß","½Ã¹ú","¾¾ºÎ¶ö","¾¾ºÎ·²","¾Ã","½Ê»õ³¢","½Ê»õ","½Ê½¦ÀÌ","18³ð",
			"18³Ñ","18³â","Á¿","¹ÌÄ£³ð","¹ÌÄ£³Ñ","¹ÌÄ£³â","¹ÌÄ£»õ³¢","¿ÀÀÔ","¿°º´","¿¥º´","Áö¶ö","Á¥¹ä","°³œq","°³½¦","°³»Ô","°³»õ","°³¼¼","°³»õ³¢",
			"°³ÇãÁ¢","µù½Ã","µù½Å","µ¹¾ÆÀÌ","¶Ê¾ÆÀÌ","¶Ë","¹ÌÃì","¹ÌÄ£","¹ÌÆ¾","ºé½Å","º´½®","ºù½Ã","ºù½Å","º´½Å","¹ð½Å","»õ.³¢","½Ê»õ","½Ê¼¼",
			"¾Ã»õ","¾Ã¼¼","¾¾ÆÅ","½Ã´ó","¾¾´ó","¾¾ÆÄ","½Ã´ó","¾¾ÆÈ","¾¾¹ß","¾ºÆÄ","¾¾ºÀ","¾¾¹æ","¾¾¹æ»õ","¾¾¹æ¼¼","¾¾¹æ","¼¼³¢","½¬ÆÞ","½¬¹ú",
			"¾¯ÆÞ","¾¯¹ú","¾¯»¹","½¬»¹","ÁÖÁ¢¶³","Áö¶ö","Áö·Ñ","Áö·²","Á½±î","ÁÖµÕ¾Æ¸®","ÁÖµÕÀÌ","ôÈ","Á¥ ¹ä","°³ œq","°³ ½¦","°³ »Ô","°³ »õ",
			"°³ ¼¼","µù ½Ã","µù ½Å","¹Ì Ä£","¹Ì Ãì","¹Ì Æ¾","ºé ½Å","º´ ½®","ºù ½Ã","ºù ½Å","º´ ½Å","¹ð ½Å","ºü °¡","»õ.³¢","»õ ³¢","½Ê »õ","½Ê ¼¼","¾Ã »õ",
			"¾Ã ¼¼","¾¾ ÆÅ","¼½ ½º","½Ã ´ó","¾¾ ´ó","¾¾ ÆÄ","½Ã ´ó","¾¾ ÆÈ","¾¾ ¹ß","¾º ÆÄ","¾¾ ºÀ","¾¾ ¹æ","¾¾ ¹æ","¼¼ ³¢","½¬ ÆÞ","½¬ ¹ú","¾¯ ÆÞ",
			"¾¯ ¹ú","¾¯ »¹","½¬ »¹","¾Ö ÀÚ","Áö ¶ö","Áö ·Ñ","Áö ·²","Á½ ±î","½Ö´¤","¾¾¹Ù¶ö","¸ÞÄ£³ð","°³¼Ò¸®","Á¶±î","¾¾ºÒ","°³½ÃÅ°","°³¼¨³¢","¾²¹ß","»õ²¥", 
			"ÈÄ·ñ","È£·Î»öÈ÷","È£·Î»õÅ°","°³½Ø³¢","°³Á¿¹ä","°³ÁÀ¹ä","°³Á¿Áö¶ö","°³ÁÀÁö¶ö","¾Ö¹Ì³â","¿¡¹Ì³â","¾Ö¹Ìº¸Áö","¿¡¹Ìº¸Áö",
			"10½ê","10¼¼Å°","10¼½È÷","¾Ã¶¯ÀÌ","¾ÃÅÊÀÌ","¾¾ÆÈ³â","¾¾¹ß³Ñ","¾¾¹ß³ð","¾¾¹Ù¶ö","¾¾¹ß","¾¾¹æ¼¼","¾¯¹Ù","½âÀ»³ð","½á±Û³ð","½âÀ»³Ñ","½á±Û³Ñ",
			"¾²¹ú","´×±â¸®","´Ï±â¹Ì","¾Ö¹Ì¹Ì","¿¡¹Ì","°³È£·ªÀÚ½»");
		
	for (i = 0; i <= slang.length; i++)  if (message.indexOf(slang[i]) >= 0) {
		alert("Çã¿ëµÇÁö ¾ÊÀº ´Ü¾î°¡ Æ÷ÇÔµÇ¾î¼­ °Ô½Ã¹° µî·ÏÀÌ µÇÁö ¾Ê½À´Ï´Ù.("+slang[i]+")");
		return false;
	}
		
	return true;
}

/* =================================================================
	syncChkHtmlFilter()
	Çã¿ëÇÏÁö ¾Ê´Â ÅÂ±× Ã¼Å©
--------------------------------------------------------------------
	formField	Form Field
	message	Form Field Value
================================================================= */
function syncChkHtmlFilter(formField, message) {
    shtmltag = new Array("<script", "</script>", "&lt;script", "&lt;/script&gt;", "function", "exec", "<iframe", "</iframe>", "<object", "</object>", "<embed", "</embed>", "<form", "</form>", "<input", "</input>", "<textarea", "</textarea>", "<select", "</select>");
	
	for (i = 0; i <= shtmltag.length; i++)  if (message.toLowerCase().indexOf(shtmltag[i]) >= 0) {
		alert("Çã¿ëµÇÁö ¾ÊÀº ÅÂ±×°¡ Æ÷ÇÔµÇ¾î¼­ °Ô½Ã¹° µî·ÏÀÌ µÇÁö ¾Ê½À´Ï´Ù.("+shtmltag[i]+")");
		return false;
	}
	return true;
}
/* =================================================================
syncChkHtmlFilter()
Çã¿ëÇÏÁö ¾Ê´Â ÅÂ±× Ã¼Å©
--------------------------------------------------------------------
formField	Form Field
message	Form Field Value
================================================================= */
function syncChkHtmlFilter2(formField, message) {
    shtmltag = new Array("<script", "</script>", "&lt;script", "&lt;/script&gt;", "function", "exec", "<iframe", "</iframe>", "<object", "</object>", "<embed", "</embed>", "<form", "</form>", "<input", "</input>", "<textarea", "</textarea>", "<select", "</select>");

	for (i = 0; i <= shtmltag.length; i++) if (message.toLowerCase().indexOf(shtmltag[i]) >= 0) {
		alert("Çã¿ëµÇÁö ¾ÊÀº ÅÂ±×°¡ Æ÷ÇÔµÇ¾î¼­ °Ô½Ã¹° µî·ÏÀÌ µÇÁö ¾Ê½À´Ï´Ù.(" + shtmltag[i] + ")");
		return false;
	}
	return true;
}
function syncChkHtmlFilter2_Event(formField, message) {
    shtmltag = new Array("<script", "</script>", "&lt;script", "&lt;/script&gt;", "function", "exec", "<iframe", "</iframe>", "<object", "</object>", "<embed", "</embed>", "<form", "</form>", "<input", "</input>", "<textarea", "</textarea>", "<select", "</select>");

	for (i = 0; i <= shtmltag.length; i++) if (message.toLowerCase().indexOf(shtmltag[i]) >= 0) {
		alert("Çã¿ëµÇÁö ¾ÊÀº ÅÂ±×°¡ Æ÷ÇÔµÇ¾î¼­ °Ô½Ã¹° µî·ÏÀÌ µÇÁö ¾Ê½À´Ï´Ù.(" + shtmltag[i] + ")");
		return false;
	}
	return true;
}
