Home > Article > Web Front-end > How to Make Text Wrap in a TD Element?
Wrap Text in Problem: You wish to wrap text within a table cell ( Answer: Wrap TD Text To effectively wrap text within a Set Table Style: This ensures that the table width is fixed, allowing the text to wrap without exceeding the width of the table. Set TD Style: This enables word-wrapping within the table cells. By following these steps, you can wrap text within The above is the detailed content of How to Make Text Wrap in a TD Element?. For more information, please follow other related articles on the PHP Chinese website! Tag
element) but have found that setting style="word-wrap: break-word;" width="15%" does not wrap the text.
element, follow these steps:
table {
table-layout: fixed;
}
td {
word-wrap:break-word
}
elements even with restricted cell widths. Related articles
See more Elements for Readability?