View Full Version : border-collapse hiding some outside borders

10-14-2004, 04:29 PM
Here's the page in question, http://www.rajetter.com/order.html.

IE6 hides the right side border for certain td's. Opera and Firefox close all the borders.

This is all of the CSS being applied:

table { border-collapse:collapse; }
td { border:solid 1px #666; }
.label { text-align:right; }

I realize I could add a border to the table itself to close these open borders, but the plan is to remove the borders for empty cells, so adding a border to the table defeats the purpose.

Anyone know why this happens or care point out what I may be doing wrong?

10-14-2004, 07:16 PM
Have you tried to set a margin for the input elements? They are making the cell to big and so they are not having the right borders applied. If that doesn't work, expand the cell widths.

10-14-2004, 09:08 PM
Thanks for the suggestion. After looking at it some more it wasn't the inputs or the border-collapse.

I had given some of my colspan's the wrong value. Damn tables.

Funny... IE exposed the error while Firefox and Opera rendered my mangled code as if it were okay.

10-15-2004, 01:38 AM
Until border-collapse is more reliable, I'm sticking with this approach if I want a table with borders on all sides of all cells:

table {border-top: 1px solid #000; border-left: 1px solid #000;}
th,td {border-right: 1px solid #000; border-bottom: 1px solid #000;}