Solution for <pre></pre> to keep the format
|
11-05-2010, 12:37 AM
Post: #1
|
|||
|
|||
Solution for <pre></pre> to keep the format
You can use CSS to make the text wrap:
pre { white-space: pre-wrap; /* css-3 */ white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ white-space: -pre-wrap; /* Opera 4-6 */ white-space: -o-pre-wrap; /* Opera 7 */ word-wrap: break-word; /* Internet Explorer 5.5+ */ } If you don't want the text formatting changed at all, this CSS will use scrollbars to make all of the text viewable anyway: pre { width: 100%; overflow: auto; } |
|||
« Next Oldest | Next Newest »
|