I have some text in a paragraph. My problem is that when punctuation is at the end of a word, it can sometimes be wrapped to the next line. Like this:
This is the text
, This is a new line
Can I resolve this with CSS or jQuery?
If you don't put a space between the word and the punctuation, and that it is wrapped anyway, you can use the white-space: nowrap;
css instruction. Otherwise, if you need a space between the word and the punctuation, like before a ?
, use the non-breaking space code. You can have it by typing alt + 0160
on your keyboard if you're using Windows. For more keyboard methods, read this.
I hope it will help.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With