Sidebar with floating to the right

streamview

New Member
I feel so dumb right now, because I'm coding my own PHP sctipt, and I've problem with CSS. Anyway. My problem is that, I can not make the sidebar to float the right side. Actually, It works, but when the content in the middle is finishing, then the boxes are moving to the middle.My CSS of sidebar:\[code\]#wb_page_content_right {float: right;width: 240px;height: auto;\[/code\]How it looks like:http://i.imagebanana.com/img/jxp4ox3c/sidebar.pngEDITWell2 CSS\[code\].well2 { min-height: 20px; padding: 5px; margin-bottom: 20px; background-color: #f7f7f7; border: 1px solid #e3e3e3; -webkit-border-radius: 4px; -moz-border-radius: 4px; border-radius: 4px; -webkit-box-shadow: inset 0 6px 3px rgba(221, 230, 235, 1); -moz-box-shadow: inset 0 6px 3px rgba(221, 230, 235, 1); box-shadow: inset 0 6px 3px rgba(221, 230, 235, 0.05);}\[/code\]SideBlock CSS:\[code\].SideBlock h3 {font: normal 14px helvetica, arial, sans-serif;color: #f7f7f7;font-weight: bold;padding: 3px 5px;background: #e3e3e3;margin: -5px -5px 10px;text-shadow: 2px 2px 2px rgba(0,0,0,0.5);}\[/code\]HTML\[code\] <div class="row"><?php foreach ($r_side as $r_sidebar): $r_sidebar_title = $r_sidebar->title; $r_sidebar_text = $r_sidebar->text; ?><div id="wb_page_content_right"><div class="well2"> <?php if (!isset($r_side)){ echo 'You can change it in ACP.'; } else { echo '<div class="SideBlock"><h3>'.$r_sidebar_title.'</h3></div>'; } eval('?>'. $r_sidebar_text)?></div></div><? endforeach; ?></div>\[/code\]The CSS is based on BootStrap.Thank you for your interest. :)
 
Back
Top