Table won't adjust width for floated element?

I have a sidebar menu and a table. The menu is created from a list floated to the left. The table's width is set to 100% to extend it to the container div's edge. However, it totally ignores the menu by keeping its width the same as it would if the menu wasn't there, causing the table to extend beyond the page boundaries.

As I understand, this should be expected behaviour due to floated elements being taken out of the normal flow. However, I due to this, I have absolutely no clue on how to make the table fill the rest of the container div and that's it.

I know that this is probably a very easy question, but for some reason I cannot find the answer.

Posted Jul 3, 2010, 12:10 AM UTC · edited

06
Loading comments…