visionsbyfurks Posted November 8, 2022 Share Posted November 8, 2022 (edited) Hello, My website: http://www.furkhaniqbal.com I have applied an a hover effect to my images (see below): img:hover {transform: scale(1.1); transition: .4s;} img{transform: scale(1); transition: .4s;} I wanted this hover to appear only on images with hyperlinks, however at the moment it is applying the effect to every image I add onto the website.How do I change this so it only applies to hyperlinked images? Thanks Edited November 8, 2022 by visionsbyfurks Forgot to add website URL Link to comment
joseph81 Posted November 8, 2022 Share Posted November 8, 2022 Then just add another a selector before the img selector: a img:hover {transform: scale(1.1); transition: .4s;} a img{transform: scale(1); transition: .4s;} tuanphan 1 Jozsef Kerekes - Front-end developer and Squarespace enthusiast My Blog: https://ui-workarounds.comIf you like my answer, please give me an upvote/like. Highly appreciated. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment