I give my links a background color to make it stand out, the problem is that it will also apply to links which have images as child instead of text. The result is that the image has a small background at the bottom. (see: http://blog.cmstutorials.org/reviews/general/featured-tutorial-of-the-week-05-feb-2011 )
How do i removed the background of links when it has an img as a child? I though that someting like this would work:
.featured_tutorial img < a
CSS does not support a
parentselector.You have to use classes like
a.this_link_contanis_img{ /*override background*/ }Or maybe you could set a new property to the img. This could hide the link’s background.
.featured_tutorial img{ /*override background*/ }Edit: Ok, that wont work in your case..