티스토리 뷰
728x90
반응형
키 또는 마우스 이벤트의 경우이 속성은 눌러 된 특정 키 또는 버튼을 나타냅니다.
Description: For key or mouse events, this property indicates the specific key or button that was pressed.
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-latest.js"></script>
</head>
<body>
<input id="whichkey" value="type something">
<div id="log"></div>
<script>$('#whichkey').bind('keydown',function(e){
$('#log').html(e.type + ': ' + e.which );
}); </script>
</body>
</html>
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-latest.js"></script>
</head>
<body>
<input id="whichkey" value="type something">
<div id="log"></div>
<script>
$('#whichkey').bind('mousedown',function(e){
$('#log').html(e.type + ': ' + e.which );
});
</script>
</body>
</html>
상세 설명: http://api.jquery.com/event.which/
728x90
반응형
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
TAG
- 스프링 프레임워크(spring framewordk)
- system.io
- 문자 자르기
- 메이븐(maven)
- React
- java-개발 환경 설정하기
- REST API
- 특정 문자를 기준으로 자르기
- MainActor
- jstl(java standard tag library)
- 표현 언어(expression language)
- In App Purchase
- 제품 등록
- error-java
- java.sql
- 스프링 프레임워크(spring framework)
- await
- java web-mvc
- 스프링 시큐리티(spring security)
- 진수 변환
- jsp 오픈 소스
- 람다식(lambda expression)
- nl2br
- System.Diagnostics
- .submit()
- java 키워드 정리
- 인텔리제이(intellij)
- jstl(java standard tag library)-core
- docker
- 스프링 시큐리티(spring security)-http basic 인증
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
글 보관함