CSS Word-Wrap

- by admin

This property specifies whether the current rendered line should break if the content exceeds the boundary of the specified rendering box for an element (this is similar in some ways to the ‘clip’ and ‘overflow’ properties in intent.) This property should only apply if the element has a visual rendering, is an inline element with explicit height/width, is absolutely positioned and/or is a block element.

 

Examples








div { word-wrap: break-word } 

<div style=”word-wrap: break-word”>Here is some content for the div element</div>

 

Possible Values

















Value Description
normal Content will exceed the boundaries of the specified rendering box.
break-word Content will wrap to the next line when necessary, and a word-break will also occur if needed.