Reputation: 565
I have a string in a div: Test: AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
Using a the word_wrap CSS class found on Stack Overflow,
/* Source: http://snipplr.com/view/10979/css-cross-browser-word-wrap */
.wordwrap {
white-space: pre-wrap; /* CSS3 */
white-space: -moz-pre-wrap; /* Firefox */
white-space: -pre-wrap; /* Opera <7 */
white-space: -o-pre-wrap; /* Opera 7 */
word-wrap: break-word; /* IE */
}
it appears like this:
Test:
AAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAA
How can I wrap it so Test: and the A's are on the same line?
Upvotes: 0
Views: 163
Reputation: 30394
Use a
instead of a regular space:
Test: AAAAAAAAAAAAAAAAAAAA
Upvotes: 2