Borders on hyperlinked images
-
Hey all. Recently I fiddled with the coding on my site to replace all underliing for hyperlinks with borders. The idea was that if I used borders I could get dotted and dashed effects, whereas hyperlinks only allow solid bars.
This post should show the problem. Hover over an image:
https://michaeldowney.net/adventures-on-yakushima/
I changed the code to add dotted borders to the links:
a{ text-decoration: none; color: #00736a; border-bottom: 1px dotted #00736a; } a:hover {border-bottom: 0 none;} a img{ border: 0 none; }
But this also adds borders to the hyperlinked images. I managed to remove it from my sidebar images (the flags), but have been unsuccessful in doing it from the images in my posts I’m guessing because I cannot apply the following code to the .entry class where my posts are placed. (If I applied a border-bottom command there, it would negate the borders on everything, including my links).
Here is the code in my sidebar to stop borders on the flag images:
#sidebar .language a{ border-bottom: 0 none; }
Any ideas how I can do the same thing for images on the whole site? I only want hyperlinked text to have a bottom-border.
- The topic ‘Borders on hyperlinked images’ is closed to new replies.