Hide and Show in Javascript


Source Code

<!DOCTYPE html>
<html>
  <head>
    <title>Javascript Output Possibilities</title>
    
    <!--Meta Tag-->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
  </head>
  <body>
    <h3>Change Content using innerHTML</h3>
    <p id="para">Add 5 and 11 </p>
    <button type="button" onclick="add();">ADD</button>
    
    <!--Script Tag-->
    <script>
    function add()
    {
     document.getElementById('para').innerHTML="Result :"+(5+11);
    }
    </script>
  </body>
</html>
To download raw file Click Here

Learn All in Tamil © Designed & Developed By Tutor Joes