Colspan not working in IE

E

Els

tshad said:
I have a table that has 2 columns and the first row is
spanning both columns.

It works fine in Mozilla, but in IE, it just wraps in the
first column.

http://www.payrollworkshop.com/development/colspantest.htm

It's probably because you gave the one with colspan the same
width ass the one that's only one column wide.
Different browsers respond differently to this, I personally
always make sure I only set widths to single column cells, and
let the colspan cells take up whatever is dictated by the single
ones.
 
D

Disco Octopus

tshad wrote :
I have a table that has 2 columns and the first row is spanning both columns.

It works fine in Mozilla, but in IE, it just wraps in the first column.

http://www.payrollworkshop.com/development/colspantest.htm

Thanks,

Tom

You may look into the <colgroup><col> stuff....
put this...
<colgroup>
<col width="160">
</colgroup>

after the <table> tag, and before the first <tr>.

I havent used it before, but it looks like it would do the trick.
 
B

Blinky the Shark

Els said:
It's probably because you gave the one with colspan the same
width ass the one that's only one column wide.

I can't help but reminisce for a moment about my first two
ex-wives having the same width ass, too... ;)
 
E

Els

tshad said:
Here is another example:

http://www.payrollworkshop.com/development/defaulttest4.htm

If you change the alignment to be right it moves about 2
characters to the right and still wraps the same way. You
can see where the cells would normally break. Way over to
the right.

Tom

Tom/Tshad,

You aren't replying to what I wrote, so why did you press
reply to message?
FWIW: in this new example you mentioned, you make the same
mistake again: you define a width to a colspan cell.
Plus: you say it's 120px wide. It's the only cell in the row.
The table you tell to be 550 wide. How do you expect the table
to behave?!
 
E

Els

tshad said:
When I made the change you suggested it worked as expected.

http://www.payrollworkshop.com/samples/colspantest2.htm

Why did Mozilla do span the 2 columns?

Because you told it to :)
Obviously, IE is doing it correctly.

No, I don't believe it's correct what IE does. It guesses what
you mean, while you were saying that 120 = 550.

If I'm going to the shop and ask for 2 loafs of bread, of which
2 brown and 1 white. What is the correct behaviour for the
shopkeeper? ;-)
 
T

tshad

Els said:
Because you told it to :)


No, I don't believe it's correct what IE does. It guesses what
you mean, while you were saying that 120 = 550.

If I'm going to the shop and ask for 2 loafs of bread, of which
2 brown and 1 white. What is the correct behaviour for the
shopkeeper? ;-)

So really - Neither one was doing correctly - or at least Mozilla was
ignoring my obvious error (even if it was not obvious to me at the time) and
doing it the way I wanted. :)

Thanks,

Tom
 

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

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top