Help- CSS styles for text links also affecting image links
Posted
by
blabus
on Stack Overflow
See other posts from Stack Overflow
or by blabus
Published on 2011-01-14T00:50:26Z
Indexed on
2011/01/14
0:53 UTC
Read the original article
Hit count: 212
I've been working on this one for about an hour now, and I'm about ready to pull my hair out. What seems like it should be a simple one or two lines of CSS apparently isn't. I have a Posterous blog with a custom theme I designed for a client, viewable here: http://phar-ma.com/
I obviously use CSS to style the text links in the posts. My problem is, the same styles are also being applied to images that have a larger version to view, since Posterous automatically turns them into links to the larger versions (the smaller images aren't turned into links). So basically I need to figure out how the return the styling of the link images to the same as the non-link images. Right now they have weird spacing and borders around them (because of the styles for the text links) and those change when you hover over them. They're also not centered correctly. I've tried just about every piece of CSS code I know, and I've had absolutely no luck. I also searched on Google and found this: http://perishablepress.com/press/2008/10/14/css-remove-link-underlines-borders-linked-images/ but still no luck with that either.
So, if anyone has any ideas, I'd appreciate it. Thanks!
© Stack Overflow or respective owner