I use Bootstrap 3 and jQuery 1.9.1 to make a site where the profile image is displayed in the <li> . I want to show the "Refresh Image" link when I smoke over the image. So far I managed to fade the image when hovering over it, but I canβt show the link or text hanging above the image. Here are my codes
JQuery
$(function () { $(".img-profile").hover( function () { $(this).fadeTo(200, 0.45); }, function () { $(this).fadeTo(200, 1); }); });
CSS
.img-profile { margin-top: 10px; width: 200px; height: 250px; }
HTML
<div class="navbar-default sidebar" role="navigation"> <div class="sidebar-nav navbar-collapse"> <ul class="nav" id="side-menu"> <li> <img class="img-responsive img-rounded img-profile" src="myimage.png" alt="profile_pic" /> </li> </ul> </div> </div>
I searched for other sources, but none of them work, as this will lead to errors of my own CSS styles. How can I show the link in the middle of the image on hover? Need this help badly! Thanks.
source share