Document onkeypress event action : onkeypress : Document JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Document » onkeypress »

 

Document onkeypress event action

















<html>
<head>
<script language="JavaScript" type = "text/javascript">
<!--

document.onkeypress = DisplayMsg;

function DisplayMsg()
{
    window.alert("You just pressed a key.");
}

//-->
</script>
<title>Keyboard Event</title>
</head>
<body>
</body>
</html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Document
» onkeypress