Wednesday 7 October 2009

Give me an alternative


I've been blogging about some "simple" stuff lately and there is a reason for that. It seems that things that those of us who have worked building big web apps for a long time, take for granted. There are certain ways to do things... etiquette even. As long as I see these things missing when I interact with the web world, they will appear here. If this is too condescending then "think you have but slumber'd here while these visions did appear".

On opening an email from my favourite pet food delivery place Star Pets in my gmail, I noticed before I hit the load all images button that the images all had place holders of a hyperlink with the text alt. This turned out to have the HTML: <img border="0" alt="alt"/>

Now, HTML elements have the alt attribute which is an alternative text attribute that is on the element in order to:
  • allow an image, link or other artifact to have a meaningful placeholder while it loads or if it fails to load;
  • allow search engine web crawlers to easily understand and index your site; and
  • assist accessibility browsers like JAWS.
As a developer, you are helping make your site easier to understand and use by people and machines. That has to be a good thing and it's not much effort. Developers, analysts and testers can all contribute to adding meaning to your pages with alt attributes so start doing it now.

It's etiquette.

1 comment:

Ed @ Cross-Country Beauty said...

alt tags are also important for the visually impaired!!

Acknowledge Me

Apple started a user experience trend many iOSes ago when it accepted Settings changes and did not ask for confirmation. Once the chang...