Wrapping title attribute

后端 未结 3 1316
难免孤独
难免孤独 2021-01-24 23:16

Firefox does not wrap words in a title attribute:


Is there a way to do word-wr

3条回答
  •  佛祖请我去吃肉
    2021-01-24 23:21

    For what it's worth, the only part of the HTML5 specifications that deals with line breaks in title attributes states:

    If the title attribute's value contains U+000A LINE FEED (LF) characters, the content is split into multiple lines. Each U+000A LINE FEED (LF) character represents a line break.

    So you could break up the title attribute on the server-side, although this is unlikely to be a desirable solution. Alternatively, you can try inserting zero width spaces, though browser support for this may also be inconsistent.

提交回复
热议问题