I know this has been asked a million times before, but I can’t seem to crack it and I’m sure someone more experienced could spot my mistake much more quickly than I could work it out.
HTML: http://sas98.user.srcf.net/guestbuzz/index.php
CSS: http://sas98.user.srcf.net/guestbuzz/style.css
I’d like the right hand box to sit on the right hand side of the form but within the container so its right hand side is aligned with the right hand side of the nav bar.
Thanks very much in advance.
Understand the block model of a div. It will take the entire width available. this works:
Note that the commented lines are another way that would work.
What did I do?.
make display:inline-block; the left and the right blocks, so it takes the necessary width and dont clear nor overlap each other.This is not necessary if you set a width.UPDATE
I now think that the best approach is to trigger a block formatting context. Make
#leftfloat to the left and to#right, give it the proppertyoverflow:auto;or any other different than visible. In IE6 you need to trigger something called hasLayout so give to#rightthe proppertyzoom:1;.