onkeypress event

by fido3993

HTML

<input type="text" onkeypress="myFunction()">

JavaScript

function myFunction() {
	alert("Hello World");
}