<!DOCTYPE html>
<html>
<body>
<input type="text" oncut="myFunction()" value="Try to cut this text">
<p id="demo"></p>
<script>
function myFunction() {
document.getElementById("demo").innerHTML = "You cut text!";
}
</script>
</body>
</html>