본문 바로가기

카테고리 없음

[자바스크립트] 입력폼 자동 넘기기

<html>
<head>
<title>주민등록번호 자동으로 넘기기</title>
<script language="javascript">
function juminCheck()
{
  var str = document.form.jumin1.value.length;
  if(str == 6)
    document.form.jumin2.focus();
}    
</script>
</head>
<body >
  <table width="421" border="0" cellspacing="0" cellpadding="0">    
    <form method="post" name="form">
      <tr>
        <td  width="421" height="35" background="img/4-16-01b.gif" align="center">
          주민등록 번호
          <input name="jumin1" size="6" OnKeyUp="juminCheck();" maxlength="6">
          -
          <input name="jumin2" size="7" maxlength="7">
        </td>
      </tr>
    </form>  
  </table>
</body>
</html>

[출처] 주민번호 자동넘기기|작성자 멋둥이

* 소피스타일™님에 의해서 게시물 이동되었습니다 (2009-06-03 12:38)