-
AuthorPosts
-
October 27, 2017 at 2:19 pm #869571
Hi,
I am using the following CSS:
.avia-image-container-inner {
box-shadow: 0px 0px 20px #D9DCDE;
}
.avia-image-container-inner:hover {
box-shadow: 0px 0px 10px #CACDCE;
}However I would like to have the effect with the inner hover only if the image is linked to an URL (only when you can click on the image). Is this possible?
Thank you in advance!
Best,
AntonOctober 29, 2017 at 11:37 pm #870259Hey tonydobrevski,
Try:.avia-image-container-inner a { box-shadow: 0px 0px 20px #D9DCDE; } .avia-image-container-inner a:hover { box-shadow: 0px 0px 10px #CACDCE; }Best regards,
MikeOctober 30, 2017 at 2:15 pm #870465Hi Mike,
This works fine. However, when using this code, it only selects the images with the links. If I use the following code:
.avia-image-container-inner {
box-shadow: 0px 0px 20px #D9DCDE;
}
.avia-image-container-inner a:hover {
box-shadow: 0px 0px 10px #CACDCE;
}
when I go with the mouse over the image, the shadow gets bigger and not smaller. Is there a way to use a code which is only for the images without links? The end goal is to have shadows on all the images and hove effect only on the ones with links. I guess the code will be something like that (but the first part should select only the images without links):
.avia-image-container-inner {
box-shadow: 0px 0px 20px #D9DCDE;
}
.avia-image-container-inner a {
box-shadow: 0px 0px 20px #D9DCDE;
}
.avia-image-container-inner a:hover {
box-shadow: 0px 0px 10px #CACDCE;
}Thank you in advance!
Best,
AntonNovember 2, 2017 at 7:30 pm #871813Hi,
Can we see the site with the code live and the exact area you have used it, so we can check the menu on hover effect please?
Best regards,
BasilisNovember 2, 2017 at 7:37 pm #871815Hi Basilis,
Yes, you can log in to the site. See how in the private content.
Best,
AntonNovember 4, 2017 at 11:41 pm #872633Hi,
To use the same effect on images without links try this:.avia-image-container-inner img { box-shadow: 0px 0px 20px #D9DCDE; } .avia-image-container-inner img:hover { box-shadow: 0px 0px 10px #CACDCE; }Best regards,
MikeNovember 5, 2017 at 5:23 pm #872773Hi Mike,
Thank you very much! Works perfectly! You can close the topic.
Best,
AntonNovember 5, 2017 at 6:15 pm #872786 -
AuthorPosts
- The topic ‘Image hover effect only when the image is linked to an URL’ is closed to new replies.
