View Single Post
  #6 (permalink)  
Old 11-18-2007, 05:13 PM
weegillis weegillis is offline
Moderator
WebProWorld Moderator
 
Join Date: Oct 2003
Location: Alberta, Canada
Posts: 879
weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6weegillis RepRank 6
Default Re: For Images: title versus alt tags? both?

Quote:
Originally Posted by weegillis View Post
The cross browser support for the correct spec is varied. Firefox has it right. IE doesn't. If you have both a title and an alt on an img, IE will still display the alternate text in the tool tip.
Okay, now who's wrong? I take that back.

Reading the thread, again, that the OP pointed to I've stumbled onto the phrase "will always override alt," and have gone and retested... Yup! It does override. Guess I'll never tire of being wrong, wrong, wrong.

Taking this back to the drawing board, let's consider an image combined with text in a single anchor, such as
HTML Code:
<a title="thisurl" href="thisurl"><img src="someimg.jpg" title="Some annotative text" alt="alternate text" />Some link text</a>
The title in the img tag overrides the title in the anchor when you mouse over the image, but does not override when you mouse over the link text. By some miracle, Firefox and IE (7) actually do the same thing.

Is this what we should expect? Why doesn't the anchor title hold sway over the entire link?

Now, let's remove the title from the img... What will happen then?

FF now shows the title on both the image and the link text. IE, on the other hand, displays the ALT text on the image, and the title on the link text. If ALT is empty, IE displays nothing over the image. In a case like this, where link text exists, is the alt text redundant? When the attribute is removed, IE displays the anchor title on both image and link text, just as FF. Which is the correct method?

Small details to be sure, but it's these kinds of inconsistencies that tend to confuse some (or many) of us. Compounding the confusion, judgment calls made years ago are AGAIN coming into question, and the reasoning of ages ago is long forgotten. All we want is to get this right, once and for all.

Accessible? Semantic? Text readers, screen readers, SEO, USERS. I don't know how Webnauts keeps up with all these. Who are we attempting to satisfy?

What would be excellent to have, on this we might all agree, is a page of really good examples that passes the scrutiny of all the experts and takes into account all the confusing questions we have. Examples usually go a lot further than explanations by themselves.

Last edited by weegillis; 11-18-2007 at 05:18 PM.
Reply With Quote