: Title attribute on image inside a tag Is there a reason to put a title attribute on an image (img tag) if this is inside a link (a tag) already with a title ? (said that you already put
Is there a reason to put a title attribute on an image (img tag) if this is inside a link (a tag) already with a title ?
(said that you already put the alt attribute to the img tag)
More posts by @Angela700
1 Comments
Sorted by latest first Latest Oldest Best
<a href="https://www.google.com" title="Hey Google Title"><img alt="Hey image alt" title="Hey image title" src="https://i.stack.imgur.com/k7vzy.png"/></a>
In above example, image title is win, but if you remove the image title tag and use only anchor title as you said in your question, then browser will pick up anchor title when someone hover the image.
I don't know why you're implementing title tag, if it is for screen reader then make sure it good written and not picked automatically from title or heading. if it is for regular user, then it is just unnecessary, I rarely see people, who hover on images to read some text.
The text around images is also enoguh to understand about the images for search engine. Quora website index/ranking for many of photos in image search without using alt and title attribute.
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.