table 中,如何使得单元格的内容不换行,单元格不被撑开
<!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>table-layout:fixed</title> <style type="text/css"> .dataTable { width: 100%; border: none; border-collapse: collapse; border-spacing: 0px !important; display: table; table-layout:fixed; } .dataTable td { word-break: break-all; word-wrap:break-word; } </style> </head> <body> <table class="dataTable" border="1"> <tr> <td width="120" align="center">阿罗裤剪短发了</td> <td width="40%"> </td> <td width="120" align="center"> </td> <td width="40%"> </td> </tr> <tr> <td align="center">阿罗裤剪短发了</td> <td> </td> <td align="center"> </td> <td> </td> </tr> <tr> <td align="center"> </td> <td> </td> <td align="center">阿罗裤剪短发了</td> <td> </td> </tr> <tr> <td align="center"> </td> <td> </td> <td align="center"> </td> <td> </td> </tr> </table> </body> </html>