0 points

JavaScript eksempel


dashboard

Sat Sep 19 2020 12:05:39 GMT+0000 (UTC)

Posted by @jaso110 #javascript #html

<!DOCTYPE html>
<html>
<body>
​
<h2>My First JavaScript</h2>
​
<button type="button"
onclick="document.getElementById('demo').innerHTML = Date()">
Click me to display Date and Time.</button>
​
<p id="demo"></p>
​
</body>
</html> 
​
content_copy Copy

https://www.w3schools.com/js/tryit.asp?filename=tryjs_myfirst