Jump to content

Div problem


thomashw

Recommended Posts

I have three DIV's. The first two I want to be beside eachother, and the last one I want to be directly below the first two.

 

I use float: left and float: right on the first two DIV's, which works to make them beside eachother, but the third is not being placed below them. It is being placed off to the right.

 

Any ideas?

Link to comment
https://forums.phpfreaks.com/topic/85693-div-problem/
Share on other sites

I know what the problem is now - I'm just not sure how to go about fixing it. A form is wrapping all three DIV's, and when I remove it they line up fine. There are inputs in the top two DIV's. Any ideas why the form is changing the formatting?

 

<form>
<div class="leftcheck"
</div>
<div class="rightcheck">
</div>
<div class="check">
</div>
</form>


.check {
border: solid 1px #000000;
float: none;
}

.leftcheck {
width: 259px;
float: left;
border: 1px solid #000000;
}

.rightcheck {
width: 259px;
float: right;
border: 1px solid #000000;
}

Link to comment
https://forums.phpfreaks.com/topic/85693-div-problem/#findComment-437350
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.