जब किसी इनपुट बॉक्स में कोई मान जोड़ा जाता है, तो oninput ईवेंट होता है। ऑनिनपुट . को लागू करने का तरीका जानने के लिए आप निम्न कोड को चलाने का प्रयास कर सकते हैं जावास्क्रिप्ट में घटना -
उदाहरण
<!DOCTYPE html>
<html>
<body>
<p>Write below:</p>
<input type = "text" id = "newInput" oninput = "inputFunc()">
<p id = "demo"></p>
<script>
function inputFunc() {
var a = document.getElementById("newInput").value;
document.write("Typed: " + a);
}
</script>
</body>
</html>