I’d like to position a table next to a floating image while keeping the width of the table 100% and not overflowing the width of the parent element.
I’ve tried various techniques but haven’t achieved the result I wanted yet. Here is what I mean: http://jsfiddle.net/AX3UR/3/
Any suggestions? Using the “overflow: hidden” property for #container is not a solution for me since essential information in table rows are lost.
Wrap the table in a div, and float it left
See the updated jsfiddle http://jsfiddle.net/AX3UR/5/
Also your
h2should not be in thepEdit
I just noticed you wanted to keep the table 100% width. This is not easy with floating.
However you could use nested tables, but that has its on pros and cons.
See http://jsfiddle.net/AX3UR/13/ for a nested table solution.