/*** * ÄÁÅÙÃ÷ : °í°´¼¾ÅÍ * ¿ë µµ : ºñÁî´Ï½º ·ÎÁ÷ Script * ÀÛ¼ºÀÏ : 2003. 10. 22 * °³¹ßÀÚ : ÃÖ¼ø¾Ö * ÀÌ ·Â : ***/ function submitForm() { var form = document.inputForm; if(document.inputForm.boardType.value == "Q02") { if(document.inputForm.market_cd.options[0].selected) { alert("»óǰÁ¾·ùÀ» ¼±ÅÃÇØÁÖ¼¼¿ä"); document.inputForm.market_cd.focus(); return; } } if(document.inputForm.counselTypeCd.value != 'W06'){ if(document.inputForm.questionTypeCd.options[0].selected) { alert("»ó´ãÀ¯ÇüÀ» ¼±ÅÃÇØÁÖ¼¼¿ä"); document.inputForm.questionTypeCd.focus(); return; } } if(checkEmail(document.inputForm.email1.value + "@" + document.inputForm.email2.value) != true) { alert("e-mailÀ» Á¤È®È÷ ÀÔ·ÂÇØ ÁÖ¼¼¿ä ¿¹)call@insvalley.com"); document.inputForm.email1.focus(); return; } /* if(form.ctelNo1.value == '' && form.ctelNo2.value == '' && form.ctelNo3.value == '' && form.telNo1.value == '' && form.telNo2.value == '' && form.telNo3.value == ''){ alert('ÈÞ´ëÆù ¹øÈ£¸¦ ÀÔ·ÂÇØ ÁÖ¼¼¿ä.'); form.ctelNo1.focus(); return; }else if(((form.ctelNo1.value != '' || form.ctelNo2.value != '' || form.ctelNo3.value != '') && !checkCTelNo.check_phone(form.ctelNo1, form.ctelNo2, form.ctelNo3, 'C')) || ((form.telNo1.value != '' || form.telNo2.value != '' || form.telNo3.value != '') && !checkTelNo.check_phone(form.telNo1, form.telNo2, form.telNo3, 'H'))){ return; } */ if(document.inputForm.title.value.length < 1) { alert("»ó´ãÁ¦¸ñÀ» ÀÔ·ÂÇØ ÁÖ¼¼¿ä"); document.inputForm.title.focus(); return; } if(checkTag(document.inputForm.title) == 'Y') return; if(document.inputForm.content.value.length < 1) { alert("¹®Àdz»¿ëÀ» ÀÔ·ÂÇØ ÁÖ¼¼¿ä"); document.inputForm.content.focus(); return; } if(checkTag(document.inputForm.content) == 'Y') return; document.all('span1').style.display = "none"; document.all('span2').style.display = ""; document.inputForm.submit(); } /* ÀüÈ­¹øÈ£ üũ */ function checkPhone(tel1, tel2, tel3, type) { cell_com = "010,011,016,017,018,019"; phone_com = "02,051,032,042,053,052,062,064,031,033,041,043,055,054,061,063"; // ±¹¹ø if((""+tel1+tel2+tel3).length < 9) return false; if((type == 1 && cell_com.indexOf(tel1) == -1) || (type == 2 && phone_com.indexOf(tel1) == -1)) return false; if(chkNumber(tel1 + tel2 + tel3) != true) return false; return true; } /* E-MAIL üũ */ function checkEmail(str) { ind_str = "1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ@.-_"; var chr; if(str.length < 6) return false; if(str.charAt(0) == '@' || str.charAt(0) == '.') return false; if(str.indexOf('@') == -1 || str.indexOf('.') == -1) return false; if(Math.abs(str.indexOf('@') - str.indexOf('.')) == 1) return false; for(x=0;x '9') { return false; } } return true; } function setSubMenu(str) { var flag = false; var position; subSelBox = document.inputForm.questionTypeCd; key = eval("key_list"); value = eval("val_list"); // ¸ðµÎ Áö¿ì±â for(i=subSelBox.length -1; i>0 ; i--) { subSelBox.options[i] = null; } for(i=0; i0 ; i--) { subSelBox.options[i] = null; } for(i=0; i0; i--){ subSelBox.options[i] = null; } for(i=0; i 0) || (len < count)) ? str.substring(st, len) : str ; } function goSubmit(url) { document.inputForm.target = "_self"; if(url == 'SEARCH_FAQ') { if(document.inputForm.searchTxt.value == '') { alert('°Ë»ö¾î¸¦ ³Ö¾îÁÖ¼¼¿ä ~'); return; } document.inputForm.cur_page.value = "1"; document.inputForm.que_type_cd.value = "ALL"; document.inputForm.searchValue.value = document.inputForm.searchTxt.value; document.inputForm.action = "/cucenter/faq/customer02_faq01.jsp"; } else if(url == 'SEARCH_INSURANCE_FAQ') { if(document.inputForm.searchTxt.value == '') { alert('°Ë»ö¾î¸¦ ³Ö¾îÁÖ¼¼¿ä ~'); return; } document.inputForm.cur_page.value = "1"; document.inputForm.que_type_cd.value = "Q02"; document.inputForm.searchValue.value = document.inputForm.searchTxt.value; document.inputForm.action = "/consult/faq/insurance_faq01.jsp"; } else if(url == 'SEARCH_MYQNA') { if(document.inputForm.searchValue.value == '') { alert('°Ë»ö¾î¸¦ ³Ö¾îÁÖ¼¼¿ä ~'); return; } document.inputForm.cur_page.value = "1"; document.inputForm.action = "/myzone/myqna/customer04.jsp"; } else { document.inputForm.action = url; } document.inputForm.submit(); } /* ÆÐ½º¿öµå È®ÀÎÇϱâ */ function checkPWD(db_type) { var h = 150; var w = 260; var winl = (screen.width - w) / 2; var wint = (screen.height - h) / 2; var winlt = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars=no,resizable' var pwdPOP = window.open('','Pwd',winlt); if(pwdPOP && !pwdPOP.closed ) pwdPOP.focus(); document.inputForm.db_type.value = db_type; document.inputForm.target = 'Pwd'; document.inputForm.action = '/cucenter/faq/checkPwd.jsp'; //document.inputForm.submit(); XecureSubmit(document.inputForm); } /* History Back*/ function goHisBack() { history.back(-1); } /*** * ³¯Â¥ SELECT BOX¿¡ 7Àϰ£ ³¯Â¥ ¼ÂÆÃ ***/ function setReservationDate() { for(i=0; i 0 ; i--) document.inputForm.hour.options[i] = null; if(str == "" || document.inputForm.select[0].selected) { // óÀ½ÆäÀÌÁö ·Îµù½Ã ¶Ç´Â ¿À´Ã³¯Â¥ ¼±Åýà ½Ã°£ ¼ÂÆÃ for(i=0; i 0 ; i--) document.inputForm.minute.options[i] = null; if(document.inputForm.hour[0].selected && document.inputForm.select[0].selected) str = ""; if(str == "") { // óÀ½ ÆäÀÌÁö ·ÎµùÀ̰ųª ¿À´Ã, ÇöÀç½Ã°£À» ¼±ÅÃÇßÀ» °æ¿ì for(i=0; i") != -1){ tmpTag = trim(value.substring(value.indexOf("<")+1, value.indexOf(">"))).toLowerCase(); value = value.substring(value.indexOf(">")+1); //alert("tmpTag=["+ tmpTag +"] \nvalue=["+ value +"]"); for(i=0; i 0) || (len < count)) ? str.substring(st, len) : str ; }