I've been working on a website featuring clickable images, but I'm struggling with the ...:hover
function. My goal is to have the image overlayed with a white color at 0.1 opacity upon hovering.
<html>
<head>
<style>
body {padding: 0; margin: 0;}
img {
margin-top: -10px;
width: 100%;
height: auto;
}
a:hover {
background-color: rgba(255, 255, 255, 0.1);
}
#asca:hover {background-color: rgba(255, 255, 255, 0.1);}
#fhca:hover {background-color: rgba(255, 255, 255, 0.1);}
#asca img:hover {background-color: rgba(255, 255, 255, 0.1);}
#fhca img:hover {background-color: rgba(255, 255, 255, 0.1);}
</style>
</head>
<body>
<a id="asca" href="asc.php">
<img src="Pictures/chevcorvette4kp.png" width="4096" height="900" alt="ascpic">
</a>
<a id="fhca" href="fhc.php">
<img src="Pictures/fhyper.png" width="4096" height="900" alt="fhcpic">
</a>
</body>
</html>
I've made multiple attempts to change the hover color without success. Any advice would be greatly appreciated.