Search code examples
cssxhtml-1.0-strict

XHTML 1.0 Strict, CSS and img borders


I am using XHTML 1.0 Strict on my website and have the following CSS style on my links:

a:hover {
    border-bottom: 1px dotted #447799;
}

and my images:

a img, img {
    border: none;
    text-decoration: none;
}

Yet, when I hover over my title banner the bottom border still shows up dotted and blue. Obviously, I can't use border="0" because it is not part of the XHTML 1.0 Strict Doctype.

You can see my site here: armorycraft.com

Suggestions?


Solution

  • You could use a class:

    a.imageAnchor:hover {
        border:none;
    }
    

    Not the most beautiful solution, but it should work.