Saturday, February 2, 2008

Correct Use of Alt Attributes in Image Tags and Title Tags in HTML

I'm currently doing some SEO on a site that sells a full-length SAT prep self-study course on DVDs, and I'm beginning to notice some basic things about HTML that I never understood (or bothered to understand, to be honest).

Alt Attributes on Image Tags

A lot of people think that these attributes are to describe the Image if it can't be found (or can't be viewed, like if you're using a text-based browser like Lynx, or if you're, more importantly, a search engine like Google). And they are for that. However, they are not DIAGNOSTIC. Let's start with the simplest case: you have a little graphic that says, "continue." Now we know you can click on it because it's surrounded by a <a> tag. So you do NOT need to write, "click here to continue." Nor do you need to write "Graphic that says continue." But best of all, you should take advantage of the possibilities for putting in relevant keywords by using an alt attribute like, "FAQs On Aspartame Testing in Technologically Enhanced Rats" (uh, assuming that's where you're going).

Now, what if your graphic is a picture of something? Sometimes, the best alt tag is a BLANK alt tag (""). For instance, if your top-nav.gif is not showing, you don't really need to say ANYTHING to the user, because there is NO translation into text of that image. But if the image can be rendered in text, go for it... but it might not be a literal translation. If you have three guys huddled around a computer, a decent alt attribute does not read, "three guys around a computer." Do NOT describe the image. Describe what the image describes, which in this case, "We work in a team-oriented environment" or "Even when computers are scarce, we get the job done" might work.

Title Tags

A lot has been written by the SEO guys on title tags, but let's just repeat the main points:
  1. Your title tag should not say, "Hey thanks for visiting" nor "Welcome to" nor "Home page of"
  2. You title tag should not say, "Stuff" nor be untitled, nor should it just say the name of your thing unless you're big and bad like IBM.
  3. You title tag should describe the contents of the PAGE, not the entire site. If you can do this on a page-by-page basis, that's the best.
  4. Remember when they made you answer those questions in high-school (or before) like, "what would be a good title for this essay?" THAT is the work you have to do to title a page. If you've ever checked out the so-called scholarly journals with the slightly too-long titles, those are probably a great example. "Three Great Things About Three Terrible Hollywood Movies from 1945-1955" is the kind of title that actually conveys something about what the article (the page, in this case) and let's the user decide CORRECTLY if he or she wants to click on it.
Now, if you've got no point and you're just getting AdSense revenues, you can probably ignore all this and put in really interesting and deceptive stuff, like "Get Rich Quick And Get Free Shipments of Viagra." But come on, there are better ways to make money than that. Although judging from the spam I get, there are a lot of guys who make serious cash with their AdSense bullshit.

Is that a myth or do they really make MAD CASH? But I digress! Anyway, those are some points about Image Tags and Title Tags in HTML. These are basically common-sense, but only after you know it (like most things).

No comments: