Code
<!DOCTYPE html>
<html>
    <head>
        <title>html tutorial - html5 - html code - html form - In 30Sec by Microsoft Award MVP - | wikitechy HTML oninput attribute</title>
    </head>
    <body>
         Enter the text:
         <input type="text" id="tutorial"  oninput="onInput()">
         <p id= "paraid"></p>
         <script>
             function onInput()
             {
               var a = document.getElementById("tutorial").value;
               document.getElementById("paraid").innerHTML = "The text is: " +a;
             }
        
</script>
    </body>
</html>

Result