|
Posted by Deephay on 09/05/07 05:57
Greetings all,
I am currently writting a 3-column full-width webpage, I have a layout
problem, here is demo of the page:
<html>
<body>
<div style="float: left; width: 25%; border-right: 1px
dashed; min-height: 20em; padding: 1em"><p>test testtest test test
test test test test test test test test test test test test test test
test test test test test test test test test test test test test test
test</p></div>
<div style="float: right; width: 25%; border-left: 1px
dashed; min-height: 20em; padding: 1em">test test test test test test
test test test test test test test test test test test test test test
test test test test test test test test test test test test test test
test test test test test test test test test test test test test test
test </div>
<div style="border: 1px solid">content content content
content content content content content content content content
content content content content content content content content
content content content content content content content content
content content content content content content content content
content content content content content content content content
content content content content content content content content
content content content content</div>
</body>
</html>
I have three columns (<div>), the width of the middle column (the last
<div>) will equal to 100% of the body width (according to CSS spec.),
but the content in that <div> will be put into the spaces between the
left and right floats according to the CSS spec, my problem is: some
times my CMS system will put a <table width="100%"><tr><td
align="center">content</td></tr>, this will break the layout of the
page because the middle column is not (100% - 2 x %25) but 100% and
the table width will be 100% either.
Specify the width of the middle column direcly in the stylesheet (45%,
say) will help, but I am not sure whether it is a good idea.
Any suggestion is very much appreciated. TIA!
Cheers,
Deephay
Navigation:
[Reply to this message]
|