Here's the task I'm trying to complete. I know how to write buttons but the function parts confuse me a lot. I know this is a very primitive question, but can anyone help? This is the script task:
<html>
<head>
<script>
function wa() {
document.getElementById('myImage').src='dm.png';
}
function aug() {
document.getElementById('myImage').src='am.png';
}
function full() {
document.getElementById('myImage').src='pm.png';
}
</script>
</head>
<body>
In this place you need to insert the code that will display an image of a waxing (am.png), waning (dm.png) and full moon (pm.png) using the three clickable buttons on the screen!
</body>
</html>
Via Active questions tagged javascript - Stack Overflow https://ift.tt/LEJHyeB
Comments
Post a Comment