I have a few instances where I place image within a link. Normally if you set border=\"0\" there line under a link does not apply to the image. However, I had to specify DOC
If you want to have a special case for links with images, give the a element a class and remove the text-decoration for that class:
HTML:
CSS:
a img
{
border: 0 none;
}
.image-link
{
text-decoration: none;
}
This is great if you only have an image within the link, however you have both text and images within the anchor.
The solution for that would be to add a span around the text within the anchor:
link text here
and add an additional style in the stylesheet:
.image-link span
{
text-decoration: underline;
}