Here is the piece of jquery code
$(".image-box").hover(
function(){$(this).css("opacity","0.6"), $(this).append("<div>Read More +</div>")},
function(){$(this).css("opacity","1"), $( this ).find( "div:last" ).remove();}
);
and here is the html
<div class="image-box">
<img class="info-img" src="https://quest.bloomu.edu/wp-content/uploads/2012/04/summer-camp-2.jpg" alt="" />
</div>
and the css where I tried to change the opacity but didn't work
.image-box div{
font-size: 3em;
color: black;
position: relative;
z-index:2;
text-align: center;
top: -60%;
bottom: -20%;
left: 2%;
opacity: 1;
border-style: solid;
border-color: black;
width:95%;
}
is there a way to disable the opacity on the child? thank you!

New Topic/Question
Reply



MultiQuote


|