Given the following table structure,
<table width=100%>
<tr>
<td>static</td>
<td>static</td>
<td>variable</td>
<td>static</td>
</tr>
</table>
I want opinions on how you'd assign width values to meet the following
criteria:
The first 2 cells of the table, as well as the last cell, need to maintain a
static width of [somevalue]... let's say 200px. The content within these
"static width" cells is guaranteed to never exceed, nor reach, 200px.
The 3rd cell containing the text 'variable' needs to span whatever space
remains between the first 2 and last cell of the table. So given the
table's overall width is "100%", spanning a horizontal vieable area of
850px, in this case the variable cell would need to end up at 250px, or
about 29%.
The way I accomplish this currently is through a brute-force implementation
of a 1x1 pixel of binary transparency streatched to 1 x 200 and inserted
just after the text in the cell, and then instructing the 3rd cell to have
a greater width than I know will ever be possible. So I end up with these
"opposing forces" pushing against each other, filling out the space as
intended:
<table width=100%>
<tr>
<td>static<br><img src=spacer.gif width=200 height=1></td>
<td>static<br><img src=spacer.gif width=200 height=1></td>
<td width=100%>variable</td>
<td>static<br><img src=spacer.gif width=200 height=1></td>
</tr>
</table>
Unfortuantely... and I think it's ie 5 for mac (can't remember) but one of
my clients can see those transparent gifs, and while it's not a total deal
breaker it's a bit of a turn-off for me. So I'd like to get rid of the
gifs, if I can. What other methods can I implement to accomplish this goal?