키를 놓으면 onkeyup 이벤트가 트리거됩니다.
예시
다음 코드를 실행하여 onkeyup 작업 방법을 배울 수 있습니다. 자바스크립트의 이벤트 -
<html>
<head>
<script>
<!--
function sayHello() {
var str = document.getElementById("subject");
str.value = str.value.toLowerCase();
}
//-->
</script>
</head>
<body>
<p>Enter subject below in upper case and see what happpens.</p>
<input type = "text" onkeyup = "sayHello()" id = "subject">
</body>
</html>