Hi
I am having a noobie problem which I was hoping somedody could assist me on. Basically I have a table and I defined the width to be 100%. I then made the 1st and second row’s cells to be 60,20 and 20%, followed by the third and 4th rows which are a 100%. So far the table is exactly how I want it and here is the code:
<html>
<body>
<table border=”1″ width=”100″>
<tr border=”1″>
<td width=”60″>ks</td><td width=”20″>ks</td><td width=”20″>ks</td>
</tr>
<tr border=”1″>
<td width=”60″>ks</td><td width=”20″>ks</td><td width=”20″>ks</td>
</tr>
<tr border=”1″>
<td colspan=”100″>ks</td>
</tr>
<tr border=”1″>
<td colspan=”100″>ks</td>
</tr>
</table>
</body>
</html>
Now assume I want to add a 5th row with data cell sizes as 20,60 and 20%. What happens when I add this row is that the cells in the 1st and 2nd row get changed to the same size as the cells in the 5th row. Anybody know how I can make the 1st and 2nd ones stay the same and have the 5th one be 20,60 and 20%? Here is my current code with the 5th cell:
<html>
<body>
<table border=”1″ width=”100″>
<tr border=”1″>
<td width=”60″>ks</td><td width=”20″>ks</td><td width=”20″>ks</td>
</tr>
<tr border=”1″>
<td width=”60″>ks</td><td width=”20″>ks</td><td width=”20″>ks</td>
</tr>
<tr border=”1″>
<td colspan=”100″>ks</td>
</tr>
<tr border=”1″>
<td colspan=”100″>ks</td>
</tr>
<tr>
<td width=”20″>ks</td><td width=”60″>ks</td><td width=”20″>ks</td>
</tr>
</table>
</body>
</html>
I have tried using colspan and also absolute values but it doesn’t give me the exact cell length I want. Please can somebody show me how to do this.
Many thanks