html - Set same width 2 tables -
i have 2 tables show data database.
now set 1st table headlines , 2nd table data.
i set this
<table class="t_status"> <td>no</td> <td>name</td> <td>address</td> </table> in table #2
<table class="t_status"> <td>1</td> <td>michael</td> <td>california</td> <tr> <td>2</td> <td>greg</td> <td>la</td> now facing problem when data display, table 1 , table 2 set different width.
this css
table { empty-cells: show; border-collapse: collapse; width: 100%; } .t_status { border-collapse: collapse; background: #fff; border: 1px solid #d9d9d9;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px; width: 100%; margin-top: -1px; } .t_status td, th { border-top: 1px solid #c0c0c0; border-bottom: 1px solid #c0c0c0; border-left: 1px solid #c0c0c0; border-right: 1px solid #c0c0c0; padding: 10px; font-size: 40pt; font-weight: bold; } .t_status td { color: #fff; background-color: #000; } .t_status th { font-size: 40pt; color: #fff; }
try put them this:
<table class="t_status"> <tr> <td>no</td> <td>name</td> <td>address</td> </tr> </table> and
<table class="t_status"> <tr> <td>1</td> <td>michael</td> <td>california</td> </tr> <tr> <td>2</td> <td>greg</td> <td>la</td> </tr> </table>
Comments
Post a Comment