엔터치면 다음칸으로 이동.

<html>
<head>
    <title>다음칸</title>
<script language='javascript'>

   var is_submit = true;
   var _NEXT_FOCUS = ""; // 커서가 갈 곳..

   function check_form(){

       f = document.form;

      if(is_submit == true){
         return true;
      }else{
         f[_NEXT_FOCUS].focus();
         is_submit = true;
         return false;
     }
   }

   function next_input(next_focus){
     if(event.keyCode == 13){
          is_submit = false;
         _NEXT_FOCUS = next_focus;
      }
   }

</script>


<body>
입력폼 아무곳에서나 엔터키를 쳐보세요..

<form name='form'>
   <input type='text' size=20 name='put1' onKeyDown="next_input('put2');"><br>
   <input type='text' size=20 name='put2' onKeyDown="next_input('put3');"><br>
   <input type='text' size=20 name='put3' onKeyDown="next_input('put4');"><br>
   <input type='text' size=20 name='put4' onKeyDown="next_input('put5');"><br>
   <input type='text' size=20 name='put5' onKeyDown="next_input('put1');"><br>
   <input type='submit' value='보내기' onClick='return check_form();'>
</form>

</body>
</html>
[이 게시물은 관리자님에 의해 2011-10-31 17:16:08 PHP & HTML에서 이동 됨]
|

댓글 3개

댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
16년 전 조회 1,852
16년 전 조회 3,712
16년 전 조회 4,559
16년 전 조회 3,206
16년 전 조회 2,463
16년 전 조회 2,550
16년 전 조회 2,784
16년 전 조회 2,287
16년 전 조회 5,660
16년 전 조회 3,482
16년 전 조회 1,462
16년 전 조회 1,817
16년 전 조회 5,181
16년 전 조회 2,423
16년 전 조회 3,509
16년 전 조회 2,788
16년 전 조회 1,671
16년 전 조회 5,490
16년 전 조회 2,597
16년 전 조회 6,089
16년 전 조회 2,047
16년 전 조회 4,122
16년 전 조회 3,145
16년 전 조회 2,321
16년 전 조회 2,345
16년 전 조회 4,506
16년 전 조회 3,402
16년 전 조회 2,937
16년 전 조회 3,077
16년 전 조회 2,195
16년 전 조회 1,882
16년 전 조회 1,805
16년 전 조회 1,510
16년 전 조회 1,790
16년 전 조회 2,008
16년 전 조회 1,708
16년 전 조회 4,955
16년 전 조회 3,956
16년 전 조회 1,903
16년 전 조회 1,651
16년 전 조회 2,390
16년 전 조회 4,652
16년 전 조회 3,653
16년 전 조회 2,702
16년 전 조회 4,442
16년 전 조회 3,311
16년 전 조회 1,465
16년 전 조회 1,484
16년 전 조회 2,149
16년 전 조회 1,995
16년 전 조회 2,713
16년 전 조회 2,332
16년 전 조회 1,478
16년 전 조회 4,508
16년 전 조회 1,594
16년 전 조회 1,894
16년 전 조회 2,310
16년 전 조회 3,984
16년 전 조회 2,882
16년 전 조회 1,590
16년 전 조회 4,155
16년 전 조회 1,508
16년 전 조회 1,687
16년 전 조회 1,355
16년 전 조회 1,823
16년 전 조회 1,730
16년 전 조회 1,740
16년 전 조회 1,520
16년 전 조회 2,285
16년 전 조회 1,914
16년 전 조회 2,076
16년 전 조회 2,294
16년 전 조회 1,582
16년 전 조회 2,453
16년 전 조회 2,356
16년 전 조회 4,635
16년 전 조회 1,415
16년 전 조회 1,152
16년 전 조회 2,113
16년 전 조회 2,085
16년 전 조회 1,624
16년 전 조회 2,174
16년 전 조회 2,388
16년 전 조회 1,496
16년 전 조회 1,857
16년 전 조회 2,034
16년 전 조회 1,120
16년 전 조회 1,819
16년 전 조회 1,505
16년 전 조회 2,017
16년 전 조회 1,427
16년 전 조회 2,319
16년 전 조회 2,004
16년 전 조회 6,001
16년 전 조회 2,022
16년 전 조회 3,799
16년 전 조회 1,565
16년 전 조회 1,854
16년 전 조회 2,204
16년 전 조회 2,729