I am not a css hacker, but here is how I would do it. Note that after floating elements you should use clear: both;
.
HTML
<div class="container"> <div id="wrapper_1"> Creating slideshows PHP </div> <div class="seperator"></div> <div id="wrapper_2"> Creating slideshows with WordPress </div> <div class="clearfix"></div> </div>
CSS
#wrapper_1 { background-color:pink; height:100px; float:left; width: 100px; } #wrapper_2 { background-color:brown; height:100px; width: 100px; float:right; } .seperator { height: 100%; width: 1px; background: black; top: 0; bottom: 0; position: absolute; left: 50%; } .container { position: relative; } .clearfix { clear: both; }
Demo : jsfiddle
user2917245
source share