wbr

Soft hyphen in HTML (<wbr> vs. ­)

◇◆丶佛笑我妖孽 提交于 2019-12-17 03:22:57
问题 How do you solve the problem with soft hyphens on your web pages? In a text there can be long words which you might want to line break with a hyphen. But you do not want the hyphen to show if the whole word is on the same line. According to comments on this page <wbr> is a non standard "tag soup invented by Netscape". It seems like ­ has its problems with standard compliance as well. There seems to be no way to get a working solution for all browsers. Which is your way for handling soft

In HTML, is it possible to insert a word wrapping hint?

旧巷老猫 提交于 2019-12-05 09:10:03
问题 Imagine I have a long, multi-word line of text in a DIV: Hello there, dear customer. Please have a look at our offer. The DIV has a dynamic width. I want to word wrap the above text. Currently, the wrapping happens on a word boundary which maximizes the length of the first line: |-DIV WIDTH------------------------------------| Hello there, dear customer. Please have a look at our offer. I would prefer that the wrapping happen on the sentence boundary. However, if no wrapping is necessary, I

In HTML, is it possible to insert a word wrapping hint?

不想你离开。 提交于 2019-12-03 22:18:17
Imagine I have a long, multi-word line of text in a DIV: Hello there, dear customer. Please have a look at our offer. The DIV has a dynamic width. I want to word wrap the above text. Currently, the wrapping happens on a word boundary which maximizes the length of the first line: |-DIV WIDTH------------------------------------| Hello there, dear customer. Please have a look at our offer. I would prefer that the wrapping happen on the sentence boundary. However, if no wrapping is necessary, I would like the line to remain as one. To illustrate my point, please look at the various DIV widths and

Soft hyphen in HTML (<wbr> vs. ­)

*爱你&永不变心* 提交于 2019-11-26 15:46:19
How do you solve the problem with soft hyphens on your web pages? In a text there can be long words which you might want to line break with a hyphen. But you do not want the hyphen to show if the whole word is on the same line. According to comments on this page <wbr> is a non standard "tag soup invented by Netscape". It seems like ­ has its problems with standard compliance as well . There seems to be no way to get a working solution for all browsers . Which is your way for handling soft hyphens and why did you choose it? Is there a preferred solution or best practice? See related SO