开发者

Image without caption

I read that in XHTML, one has to put alt-attributes to images to get a valid img-tags. But then I saw a small rectangular area as I moved my mouse over the image. Can I make an image tag which passes validatio开发者_Go百科n but it won't show that rectangle as I move mouse over the image?


Use a blank alt (IE) and do not specify the title attribute (other browsers):

<img src="myimage.png" alt="" />

The spec says you need to include the alt attribute; however it may be blank as long as you put it there.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜