遇到一个棘手的问题,即便是给td限定的宽度,但是如果里面的内容是连续的,IE就认为是一个单词,不会换行,瞎聪明,google了一通,用css把问题解决了,css这玩意太强了,收藏一下,控制td换行的css样式:style="word-wrap:break-word;word-break:break-all;"
1
<
table
width
="100%"
border
="0"
cellspacing
="1"
cellpadding
="0"
>
2 < tr >
3 < td width ="25%" style ="word-wrap:break-word;word-break:break-all;" valign ="bottom" >
4 abcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabc </ td >
5 </ tr >
6 </ table >
2 < tr >
3 < td width ="25%" style ="word-wrap:break-word;word-break:break-all;" valign ="bottom" >
4 abcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabc </ td >
5 </ tr >
6 </ table >