function MM_preloadImages() { //v3.0 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i'; object += ''; object += ''; object += '<\/embed>'; object += '<\/object>'; document.write(object); } function swf2(src, width, height, id) { object = ""; object += ""; object += ""; object += ""; object += ""; object += ""; object += " "; object += ""; object += ""; document.write(object); } function loadFlash(fname,w,h,gubun) { var oStr = ""; switch(gubun) { case "logo": oStr = "" oStr += " " oStr += " " oStr += " " oStr += " " oStr += " " oStr += " " oStr += "" break; default: oStr = "" break; } document.write(oStr); } function SwfSelect(si) { for(i=0;i= 48 && event.keyCode <= 57) { } else { event.returnValue = false } } function com(obj) { obj.value = unComma(obj.value); obj.value = Comma(obj.value); } function Comma(input) { var inputString = new String; var outputString = new String; var counter = 0; var decimalPoint = 0; var end = 0; var modval = 0; inputString = input.toString(); outputString = ''; decimalPoint = inputString.indexOf('.', 1); if(decimalPoint == -1) { end = inputString.length - (inputString.charAt(0)=='0' ? 1:0); for (counter=1;counter <=inputString.length; counter++) { var modval =counter - Math.floor(counter/3)*3; outputString = (modval==0 && counter 0 && (i%3)==0) { retValue = str.charAt(str.length - i -1) + "," + retValue; } else { retValue = str.charAt(str.length - i -1) + retValue; } } return retValue; } function winResize() { var Dwidth = parseInt(document.body.scrollWidth); var Dheight = parseInt(document.body.scrollHeight); var divEl = document.createElement("div"); divEl.style.position = "absolute"; divEl.style.left = "0px"; divEl.style.top = "0px"; divEl.style.width = "100%"; divEl.style.height = "100%"; document.body.appendChild(divEl); window.resizeBy(Dwidth-divEl.offsetWidth, Dheight-divEl.offsetHeight); document.body.removeChild(divEl); self.moveTo((screen.availWidth/2) - ((Dwidth-divEl.offsetWidth)/2), (screen.availHeight/2) - ((Dheight-divEl.offsetHeight)/2)) } function NumberCheck(frm) { val = frm.value; new_val = ''; for(i=0;i '9') { //alert('¼ýÀÚ¸¸'); frm.value = new_val; return; } else { new_val = new_val + char; } } } function CheckAlpabatNum(obj) { var str = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" for (i=0; i < obj.value.length; i++) { if (str.indexOf(obj.value.substring(i,i+1))<0) { alert('¿µ¾î¿Í ¼ýÀÚ ÀÌ¿Ü¿¡´Â ÀÔ·ÂÇÒ ¼ö ¾ø½À´Ï´Ù.'); obj.focus(); obj.value = ""; return false; } } return true; } function JuminCheck(jumin) { var na,totid,checksum; totid=0; na=0; checksum=0; for(i=1;i<=12;i++) { if(i <= 8) { totid += parseInt(jumin.charAt(i-1)) * (i + 1); } if(i > 8) { totid += parseInt(jumin.charAt(i-1)) * (i - 7); } } //na=totid % 11; na = 11 - (totid % 11); /*if(na == 0) { checksum = 1; } else if(na == 1) { checksum = 0; } else { checksum = 11 - na; }*/ if(na > 9) { checksum = na % 10; } else { checksum = na; } if(checksum == parseInt(jumin.charAt(12))) { return true; } else { return false; } } function EmailCheck(email) { var str = email; var reg = /^[0-9a-zA-Z]([-_\.]?[0-9a-zA-Z])*@[0-9a-zA-Z]([-_\.]?[0-9a-zA-Z])*\.[a-zA-Z]{2,3}$/i; if(str.search(reg) != -1) { return true; } else { return false; } } function blankchk(frmid, msg) { var frm = document.getElementById(frmid); if(!frm.value) { alert(msg); frm.focus(); return false; } else { return true; } } function ZeroCheck(str, len) { var s = str.toString(); var zero = ""; for(i=s.length+1; i<=len; i++) { zero += "0"; } return zero + str; } // ÇØ´ç ¿ùÀÇ ¸¶Áö¸·³¯À» ±¸ÇÔ function GetLastDay(year,month) { var lastdayArray=new Array(31,28,31,30,31,30,31,31,30,31,30,31) if (isLeapYear(year)) { lastdayArray[1]="29"; } else { lastdayArray[1]="28"; } return lastdayArray[month-1] } // À±³âÀΰ¡? function isLeapYear(targetYear) { if ((targetYear%4)!=0) { return false } if ((targetYear%100)==0) { if ((targetYear%400)!=0) { return false } } return true } // Á¤±Ô½Ä¿¡ ¸Â´Â°¡? (°á°ú : false/¸Þ½ÃÁö Ãâ·ÂÈÄ true ¸®ÅÏ) function isRightByRegExp(object,rPattern,rSwitch,comment) { var regObject=new RegExp(rPattern,rSwitch) regObject.compile(rPattern,rSwitch) if (regObject.test(object.value)) { return false } return alertMessage(object,comment) } // Á¤±Ô½Ä °á°ú°¡ ¿ÇÀº°¡? (°á°ú : true/false) function isRightResultByRegExp(targetString,rPattern,rSwitch) { var regObject=new RegExp(rPattern,rSwitch) regObject.compile(rPattern,rSwitch) if (regObject.test(targetString)) { return true } return false } // ¿Ã¹Ù¸¥ Áֹεî·Ï¹øÈ£Àΰ¡? (°á°ú : true/false) function isRightSocialNo(socialNo1,socialNo2) { // 1. Á¡°Ë 1 // (1) ¾ÕÀÚ¸® : ³¯Â¥ ±ÔÄ¢¿¡ ¸Â´Â°¡? if (!isRightResultByRegExp(socialNo1,"[0-9]{2}[0-1][0-9][0-3][0-9]",["g"])) { return false } // (2) µÞÀÚ¸® : ¼ºº° ±ÔÄ¢¿¡ ¸Â´Â°¡? if (!isRightResultByRegExp(socialNo2,"[1-4][0-9]{6}",["g"])) { return false } // 2. Áֹεî·Ï¹øÈ£ ¡æ ¹è¿­ var socialNo=new Array(13) var str="" for (var i=0; i<13; i++) { if (i<6) { socialNo[i]=parseInt(socialNo1.charAt(i)) } else { socialNo[i]=parseInt(socialNo2.charAt(i-6)) } } // 3. Á¡°Ë 2 // (1) ¼ºº° Ç¥±â°¡ ¿Ã¹Ù¸¥°¡ : 7¹ø° ÀÚ¸®=1~2(1900³â´ë Ãâ»ý), 3~4(2000³â´ë Ãâ»ý) var birthYear switch (socialNo[6]) { case (1) : case (2) : birthYear=1900 break case (3) : case (4) : birthYear=2000 break default : return false } // (2) »ý³â¿ùÀÏÀÌ ¿Ã¹Ù¸¥°¡ : 1~6¹ø° ÀÚ¸® // ¨ç »ý³â¿ùÀÏ birthYear+=(socialNo[0]*10)+socialNo[1] // ³â var birthMonth=(socialNo[2]*10)+socialNo[3] // ¿ù var birthDay=(socialNo[4]*10)+socialNo[5] // ÀÏ // ¨è »ý³â¿ùÀÏÀÌ ¿Ã¹Ù¸¥ ³¯Â¥Àΰ¡? if (!isRightDate(birthYear,birthMonth,birthDay)) { return false } // (3) Áֹεî·Ï¹øÈ£ ±ÔÄ¢¿¡ ¸Â´Â°¡? // ¨ç Áֹεî·Ï¹øÈ£ ±ÔÄ¢ °è»ê var multiplier=new Array(2,3,4,5,6,7,8,9,2,3,4,5) var ruleSum=0 for (var i=0; i<12; i++) { ruleSum+=socialNo[i]*multiplier[i] } ruleSum=(11-(ruleSum%11))%10 // ¨è Áֹεî·Ï¹øÈ£ ±ÔÄ¢¿¡ ¸Â´Â°¡? if (ruleSum!=socialNo[12]) { return false } // 4. ¿Ã¹Ù¸¥ Áֹεî·Ï¹øÈ£À̸é true ¸®ÅÏ return true } // Áֹεî·Ï¹øÈ£¸¦ ¿Ã¹Ù¸£°Ô ½è´Â°¡? (°á°ú : false/¸Þ½ÃÁö Ãâ·ÂÈÄ true ¸®ÅÏ) function isSocialNoRight(object1,object2,comment) { // 1. Áֹεî·Ï¹øÈ£°¡ ¿Ã¹Ù¸£Áö ¾ÊÀ¸¸é ¸Þ½ÃÁö Ãâ·ÂÈÄ true ¸®ÅÏ if (!isRightSocialNo(object1.value,object2.value)) { return alertMessage(object1,comment) } // 2. Áֹεî·Ï¹øÈ£°¡ ¿Ã¹Ù¸£¸é false ¸®ÅÏ return false } // ¿Ã¹Ù¸¥ ³¯Â¥Àΰ¡? function isRightDate(tYear,tMonth,tDay) { // 1. ³Ñ¾î¿Â ³â,¿ù,ÀÏ Date ÀνºÅϽº »ý¼º tMonth-- var targetDate=new Date(tYear,tMonth,tDay) // 2. »ý¼ºµÈ ÀνºÅϽº·ÎºÎÅÍ ³¯Â¥°¡ ¿Ã¹Ù¸¥Áö üũ ¡æ ¿Ã¹Ù¸£¸é true ¸®ÅÏ if (((targetDate.getYear()%100)==(tYear%100)) && (targetDate.getMonth()==tMonth) && (targetDate.getDate()==tDay)) { return true } // 3. ¿Ã¹Ù¸£Áö ¾ÊÀ¸¸é false ¸®ÅÏ return false } // ¿Ã¹Ù¸¥ ¿Ü±¹Àεî·Ï¹øÈ£Àΰ¡? function isRightForeignerNo(foreignerNo1,foreignerNo2) { // 1. Á¡°Ë 1 // (1) ¾ÕÀÚ¸® : ³¯Â¥ ±ÔÄ¢¿¡ ¸Â´Â°¡? if (!isRightResultByRegExp(foreignerNo1,"[0-9]{2}[0-1][0-9][0-3][0-9]",["g"])) { return false } // (2) µÞÀÚ¸® : ¼ºº° ¹× ±âŸ ±ÔÄ¢¿¡ ¸Â´Â°¡? if (!isRightResultByRegExp(foreignerNo2,"[056789][0-9]{4}[6-9][0-9]",["g"])) { return false } // 2. ¿Ü±¹Àεî·Ï¹øÈ£ ¡æ ¹è¿­ var foreignerNo=new Array(13) for (var i=0; i<13; i++) { if (i<6) { foreignerNo[i]=parseInt(foreignerNo1.charAt(i)) } else { foreignerNo[i]=parseInt(foreignerNo2.charAt(i-6)) } } // 3. Á¡°Ë 2 // (1) ¼ºº° Ç¥±â°¡ ¿Ã¹Ù¸¥°¡ : 7¹ø° ÀÚ¸®=9~0(1800³â´ë Ãâ»ý), 5~6(1900³â´ë Ãâ»ý), 7~8(2000³â´ë Ãâ»ý) var birthYear switch (foreignerNo[6]) { case 9 : case 0 : birthYear=1800 break case 5 : case 6 : birthYear=1900 break case 7 : case 8 : birthYear=2000 break default : return false } // (2) »ý³â¿ùÀÏÀÌ ¿Ã¹Ù¸¥°¡ : 1~6¹ø° ÀÚ¸® // ¨ç »ý³â¿ùÀÏ birthYear+=(foreignerNo[0]*10)+foreignerNo[1] // ³â var birthMonth=(foreignerNo[2]*10)+foreignerNo[3] // ¿ù var birthDay=(foreignerNo[4]*10)+foreignerNo[5] // ÀÏ // ¨è »ý³â¿ùÀÏÀÌ ¿Ã¹Ù¸¥ ³¯Â¥Àΰ¡? if (!isRightDate(birthYear,birthMonth,birthDay)) { return false } // (3) 8~9¹ø° ÀÚ¸®°¡ ¦¼öÀΰ¡? if ((((foreignerNo[7]*10)+foreignerNo[8])%2)!=0) { return false } // (3) ¿Ü±¹Àεî·Ï¹øÈ£ ±ÔÄ¢¿¡ ¸Â´Â°¡? // ¨ç ¿Ü±¹Àεî·Ï¹øÈ£ ±ÔÄ¢ °è»ê var multiplier=new Array(2,3,4,5,6,7,8,9,2,3,4,5) var ruleSum=0 for (var i=0; i<12; i++) { ruleSum+=foreignerNo[i]*foreignerNo[i] } ruleSum=(((11-(ruleSum%11))%10)+2)%10 // ¨è ¿Ü±¹Àεî·Ï¹øÈ£ ±ÔÄ¢¿¡ ¸Â´Â°¡? if (ruleSum!=foreignerNo[12]) { return false } // 4. ¿Ã¹Ù¸¥ ¿Ü±¹Àεî·Ï¹øÈ£À̸é true ¸®ÅÏ return true }