I stumbled across a site that gives Title Attributes to its text links: When you hover over the link it displays extra info like an ALT Image title. Is this Gray Hat or perfectly acceptable? What would be the benefit vs. disadvantage if there is any? Heres how the source looked: <a title="Cerritos Infiniti your Los Angeles, Southern California Infiniti car dealership" href="http://www.somesite.com">Cerritos Infiniti</a>
The practice is sound - and good for accessibility and usability. Their implementation of it though is somewhat suspect.
Title for link should describe what you will find following it - same as alt for image should say what's on it. If you use it in that way - its acceptable and desirable.
I use title tags for images as well as for some links when I can add more information in title tag and have limited visual space. It acts like a tooltip and shouldn't be considered black hat. Though one can always do keyword stuffing and abuse it (like in this example you have shared).
I have googled "Cerritos Infiniti" and found www.CerritosInfiniti.com first page. but in google only short title, "Cerritos Infiniti". but when I click the link, on website is different title. how can they do that? I mean technically google should read exactly title from webpage, but there is some thing different. can someone tell me how to do like that technically?
hey trosquin its fine. Just replicate or simplify what you have in the text when you use the title="" attribute. @turksweb - has the Cerritos Infiniti website updated their metatitle tag because I notice thats its been about 1 week since Google last indexed their homepage. That would be the most simple explanation.
Why do people refer to the <title> element as a meta tag? LOL If it doesn't start with <meta ...> then it's not a "meta tag". Even using the word tag is incorrect in this context. When you are talking of the entire thing (eg. <title>my title</title>), it's an HTML element. It's only a "tag" when you refer specifically to the syntax for opening/starting or closing/ending the element. For example, the <a> (anchor) element has an opening/start tag of <a> and a closing/end tag of </a>. It also has attributes like href, rel, etc. Note the terminology used by the peeps who set the standards.
There is no 'title' attribute in the 'a' tag in HTML 4.01: h++p://www.w3.org/TR/html401/struct/links.html#h-12.2
Actually, there is. It's one of a handful of attributes that can be assigned to just about any element. The same with class and ID for example.
Dan is correct. There is a title attribute for the <a> element (or the <a> start tag). It's displayed in most browsers as the hover text when you hover over a link with your mouse. Note the example they selected at w3.org for using a title attribute:
It has some, but not much. A friend of mine had one of his new sites flagged for a manual review by Google because he (like me) adhered to the LETTER of the HTML 4.01 specification rather than just the spirit. One of the things they interrogated him (yes, I said interrogated, not asked) about was his use of the title attribute to "stuff keywords" into things like abbreviation and acronym elements (ABBR and ACRONYM respectively). Needless to say, neither he nor I were very happy. At least he passed the review once they realized the attributes were used for accessibility reasons and in strict accordance to the HTML specification.