Set 99 Practical Question

⭐ Q49 – HTML + JavaScript: Picture Disappears on Click

Example Code (Read Only):


<!DOCTYPE html>
<html>
<head>
<title>Hide Image</title>

<script>
function hideImage(){
    document.getElementById("pic").style.display = "none";
}
</script>

</head>
<body>

<h2>Click Image to Hide</h2>

<img src="mikul.jpg" id="pic" width="300" onclick="hideImage()">

</body>
</html>

Write Your HTML / JavaScript Code