It's quite a simple question but I can't figure out what's wrong.
I have three divs, 2 of set pixel sizes and the other (the middle) fills the remaining space between the two.
|------|--------------------------|------|
| | | |
| | | |
| | | |
|------|--------------------------|------|
<-------------------------->
Width Fill
I have the following CSS:
Left Div
#leftdiv {
height: 50px
width: 50px;
float: left;
}
Middle Div
#middlediv {
min-width: 270px;
width: calc(100% - 100px);
width: -moz-calc(100% - 100px);
width: -webkit-calc(100% - 100px);
width: -o-calc(100% - 100px);
float: left;
}
Right Div
#rightdiv {
width: 100px;
height: 50px;
float: right;
}
I've simplified it here, but basically the right div doesn't actually float, it goes underneath like so:
|------|--------------------------|
| | |
| | |
| | |
|------|--------------------------|
|------|
| |
| |
| |
|------|