How can I use a carriage return in a HTML tooltip?

前端 未结 27 1680
说谎
说谎 2020-11-22 11:59

I\'m currently adding verbose tooltips to our site, and I\'d like (without having to resort to a whizz-bang jQuery plugin, I know there are many!) to use carriage returns to

27条回答
  •  傲寒
    傲寒 (楼主)
    2020-11-22 12:30

    As of Firefox 12 they now support line breaks using the line feed HTML entity:

    Test
    

    This works in IE and is the correct according to the HTML5 spec for the title attribute.

提交回复
热议问题