Call a function without parameter - Javascript Function

Javascript examples for Function:Quiz

Description

Call a function without parameter

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<body>

<p id="demo"></p>

<script>
function myFunction() {//  ww  w. j a  va 2s .  c o m
    document.getElementById("demo").innerHTML = "Hello World!";
}
myFunction();
</script>

</body>
</html>

Related Tutorials