index.html
<html>
<body>
<p id="p1"></p>
<script>
//diffrent ways to display hello world using js
console.log("hello world");
document.write("hello all");
document.getElementById('p1').textContent="hello world";
document.getElementById('p1').innerHTML="hello world";
</script>
</body>
</html>
No comments:
Post a Comment