Make tinymce output tag HTML code to automatically wrap

Source: Internet
Author: User

The HTML Tag obtained by tinymce contains the <PRE> </PRE> label. By default, if the content in the <PRE/> label is out of the range, the line feed is not automatically generated, in this way, it will be troublesome to display or print data.

The following provides CSS styles that comply with W3C standards and support multiple browsersCode:

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 + */
}

Note:The CSS at the upper level also needs to be set:

Word-wrap: Break-word; Word-break: Break-all;

For more information, see http://www.w3.org/tr/css3-text/?white-space.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.