开发者

Better add images through html or css?

Better add images through HTML and determine alt tags, or add through CSS with the text-indent: -9999px (or similar) property? Or is there no difference?

Does search engines take text-indent: -9999px property as a normal way of doing things? Cause with this property we actually create a text, but not showing it for t开发者_运维技巧he user.


I'd say it depends on what you're trying to make it mean. Is it an image with text fallback, or is it text with an image enhancement?

If I have an image which is just a fancier version of the text (perhaps with special effects or flourishes), I use the text with background-image and negative text-indent. If I have an image where the text does not convey the full meaning, I use <img alt>.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜