IE and fixed columns, help

S

sellmerfud

I am trying to create a table where the first row has two columns.
I want the first column to be of fixed width and the second column to
stretch to fit the rest
of the table width.

In the subsequent rows, there will a single column colspan="2" and this
column
will be wider than the first column in the first row.

In Firefox all works as planned. In IE, however, the first column in
the first row is not
fixed to the width that I specify. It is as if IE is ignoring the
width attribute.
(I have tried using width="512", style="width:512", and <col
width="512"> and IE
blissfully ignores them all.

Does anyone know how I can achieve this?
Thanks, Curt

Here is example code:

<TABLE cellpadding="0" cellspacing="0" border="1" >
<colgroup><col width="512"><col></colgroup>
<TR>
<TD>
blah blah blah blah blah blah
</TD>
<TD align="left" nowrap>Upper Right content</TD>
</TR>
<TR>
<TD colspan="2">
<TABLE cellspacing="0" cellpadding="0">
<TR>
<TD nowrap>blah blah blah blah blah blah blah blah</TD>
<TD nowrap>blah blah blah blah blah blah blah blah</TD>
<TD nowrap>blah blah blah blah blah blah blah blah</TD>
<TD nowrap>blah blah blah blah blah blah blah blah</TD>
</TR>
</TABLE>
</TD>
</TR>
</TABLE>
 
D

dorayme

I am trying to create a table where the first row has two columns.
I want the first column to be of fixed width and the second column to
stretch to fit the rest
of the table width.

In the subsequent rows, there will a single column colspan="2" and this
column
will be wider than the first column in the first row.

In Firefox all works as planned. In IE, however, the first column in
the first row is not
fixed to the width that I specify. It is as if IE is ignoring the
width attribute.
(I have tried using width="512", style="width:512", and <col
width="512"> and IE
blissfully ignores them all.

Does anyone know how I can achieve this?

Post a URL with something you are really (in the Korpela sense)
trying to do.

Why are you no wrapping? Do you know that the effect of this is
to lose the magical ability of tables to stay within the width of
the browser without needing to sideways scroll. Are you using
this table for layout? Do you need to? Do you know that in css
you have to put in the units for widths?
 
S

sellmerfud

Thanks for your reply.

I can't really post the actually code as it is being generated
dynamically via
a server side application. I'm not too versed in HTML so I'm probably
using
the wrong approach, but what I'm trying to do is this:

I have a custom tag (several tags actually) that is being used to
create
a tabbed worksheet similar to the "Options" dialogs an many microsoft
applications. I use a table to encapsulate the entire worksheet.
The top row of the table contains the folder tabs in the first column.
In the
second column I want to be able to place other stuff such as buttons,
help text, etc.
(I'm calling this "upper right content") I want the upper right content
to start just after
the folder tabs and I want for this Upper right content to be either
left justified or
right justified (controlled by an attribute to the tab).
The remainder of my table is one large row with a single column that
will contain
the contents of the currently selected folder tab.
I'm sure that there is a better way to do this (I've recently inherited
this code)
using <div> but I'm not sure how? Any suggestions are greatly
appreciated.

Thanks,
Curt
 
J

Jukka K. Korpela

Scripsit (e-mail address removed):
I can't really post the actually code as it is being generated
dynamically via
a server side application.

We can't really post you the actual answer as it is being generated in our
minds dynamically and the process stuck with the "insufficient input" wait
state.

But maybe you can learn to use reasonable-length lines and learn to quote on
Usenet (and type your name in the right place) while waiting for us while we
are waiting.

Seriously, if someone told you about table-layout: fixed, you'd probably
take it for a right answer, especially since it "works" (for some values of
"works").

But if you really want the right answer, post the right question. Hint: It
contains a URL. If you page has no URL (dynamic or not), it does not exist -
on the Web at least.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top