- This topic is empty.
-
AuthorPosts
-
February 7, 2015 at 3:09 pm #195293JerryParticipant
I am trying to have a hyphen, e.g. Mon-Tues, break at the end of a line in firefox using CSS, without success.
.couponwp p 02D:after {
content: "\200B";
}Of note, the CSS below works fine:
`.couponwp p {
font-size: 12px;
}’Thank you for your time
JerrySorry about the confusion, the forum will no accept the complete code for hyphen:after
JerryFebruary 7, 2015 at 3:35 pm #195295Paulie_DMemberA demo in Codepen might be of more help.
Is this an issue only in Firefox or other browsers too.
February 7, 2015 at 3:45 pm #195296JerryParticipantThank you for responding,
Posting on this forum is the first time I heard of codepen, I will learn how to use it.
Only a firefox issue. Fire fox will not break a hyphen at the end of a line if there is four or less characters before or after the hyphen.
Jerry
February 8, 2015 at 1:27 am #195303DanielNichesite3ParticipantReally strange. Different browse always make the different bug to developer. I often has these kind of error with IE8.
February 9, 2015 at 5:04 am #195356JerryParticipantWhen I use word-break: break-all in firefox words break like this:
some-thin
gor
somethi
ngWhen I use word-break: normal nothing happens.
Instead of trying to add the zero-width-space after the hyphen in firefox, is there a way using CSS to replace the hyphen with one that would respond to word-break: normal
Thank you for your time
Jerry
February 9, 2015 at 6:11 am #195364Paulie_DMemberI’m still a little confused…why would you have a ‘non-word’ like “some-thing”.
And why would you break “Mon-Tues”?
Are you trying to break actual hyphenated words or prevent hyphenated words from breaking.
There is an HTML entity for a non-breaking hyphen.
‑
February 9, 2015 at 7:07 am #195368JerryParticipantsome-thing was just used as a test.
I am trying to break actual hyphenated words e.g “Mon-Tues” Putting a class or code at the location of each hyphenated word e.g. “Mon-Tues”, “10:00am-11:30pm” ect… is not an option for this situation.
Thank you for responding.
Jerry
February 9, 2015 at 8:57 am #195373JerryParticipantThank you for responding,
Is it not possible to force a hyphen, e.g. Mon-Tues, to break at the end of a line in firefox using CSS ?
Jerry
February 9, 2015 at 12:48 pm #195395JerryParticipantThank you for your response. Maybe I can get the zero width space to work.
The hyphen breaks are for coupons with a narrow width.
There are a number of possibilities including word-wrap, overflow-wrap that I should probability look at again.
Thank you for your time
Jerry
February 11, 2015 at 1:04 pm #195686JerryParticipantThank you for that option. Your help has been appreciated.
Jerry
-
AuthorPosts
- The forum ‘CSS’ is closed to new topics and replies.