My First JavaScript
get source code here<!DOCTYPE html>
<html>
<body>
<head>
<style>
body {
color: rgb(33, 6, 153);
font-family: Verdana, Geneva, Tahoma, sans-serif;
}
#demo {
color: rgb(33, 6, 153);
font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
}
#demored {
color: rgb(255, 0, 0);
font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
}
</style>
</head>
<h2>My First JavaScript</h2>
<a href="https://mcqsppsc.blogspot.com"> get source code here </a>
<br><br>
<button type="button"
onclick="document.getElementById('demo').innerHTML = Date()">
Click me to display blue Date and Time.</button>
<p id="demo"></p>
<button type="button"
onclick="document.getElementById('demored').innerHTML = Date()">
Click me to display red Date and Time.</button>
<p id="demored"></p>
</body>
</html>