Quote:
Originally Posted by webmarkart
Anyway I need the heading to be absolutely positioned and the data itself to fit inside the container and if needed have a scrollbar. I pretty much have it working except that I have to use a fixed pixel width for the tables. If I use a percentage, which is what I want, the columns within the two tables no longer line up because of the scrollbar and I often get a horizontal scrollbar. Any ideas how to effectively use percentage widths in this case to keep with the fluid layout?
|
I cannot think of a pure CSS solution to this problem. JavaScript may be your best option.
To begin with, you could let the heading be as wide as the data itself + the scrollbar. Then use JavaScript to get the width of the data (minus the scrollbar) and set the width of the heading accordingly. Altogether you will get an acceptable rendering when JavaScript is disabled and an enhanced rendering when enabled.
Quote:
Originally Posted by webmarkart
In IE however I can seemingly only specify top or bottom and left or right.
|
I guess that you are referring to IE6 because in this browser you cannot simultaneously specify values for opposite offsets. More precisely, if you simultaneously specify a
top and
bottom offset, then
bottom is ignored. Similarly, if you simultaneously specify a
left and
right offset, then
right is ignored in the
ltr-direction and
vice versa.
Note that this issue has been resolved in IE7.
I'm not sure that I understand what you are trying to do, but again, JavaScript may be the solution.