The use of CSS Word-wrap properties

Source: Internet
Author: User
This is a simple code is to let long words outside the box is not large enough to be able to line the display. It still works very well in many English-language web editors.

Grammar:

Word-wrap:normal | Break-word

Parameters:

Normal: Allow content to open the specified container boundary
Break-word: Content will be wrapped within the boundary. Word Wrapping (Word-break) also occurs if needed

Description

Sets or retrieves whether a career change is broken when the current row exceeds the bounds of the specified container.
The corresponding script attribute is wordwrap. Please refer to the other bibliography I have written.

Example:

div {Word-wrap:break-word;}

Code application. In this example, we split the long words.

p.test {Word-wrap:break-word;}

This word-wrap is supported by all browsers.

Word-wrap's usage, its default value is normal its inheritance yes its version is CSS3

Style flow. When using this code, be sure to define the outer frame.

<style> p.test{width:11em, border:1px solid #000000; word-wrap:break-word;} </style>

Java applications for Word-wrap. One assignment is done.

object.style.wordwrap= "Break-word"

The grammatical word-wrap:normal|break-word of word-wrap;

Two different parameter values. One is the default browser, one is the word break.

Related Article

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.