If I have a link (anchor) in the header
that just contains an image, like this:
<a href="index.html" title="Home">
<img src="http://placehold.it/200x50" alt="Site Name">
</a>
Is this accessible? The alt
attribute appears to be overridden by the title
attribute. I know that title
is not usually necessary, but because nothing is describing the link except the alt
text (which only has the Site Name because the image is a site logo in this case), the title
is supposed to say that the link goes back home. I can't add any text because I don't want to hide it with CSS; that would not fit with progressive enhancement.
Where should the link description go in this case? Alt
or title
? What's the best practice?