April 21, 201412 yr Hi Can anyone help me with the custom css code required to make my sidebar closer to the edge of the screen There is too much padding and I want almost 0 padding www.thescottishgame.com/Blog/wordpress
April 21, 201412 yr Would you like the sidebar to be completely to the left - touching the edge of the browser at all times? Because if you don't do a responsive website, it will be different for each screen (or devices) in how they see the sidebars position. If you're into having the sidebar stuck to the left side at all times you could go with: position: absolute; left: 0px; But for that to work you need to put the sidebar outside of the inner div and into the content_box which doesn't have a limited width. Then put position: relative; into the css for content_box.If you'd like it in any other way, try and explain and I will see if I can help. Edited April 21, 201412 yr by myjosephine
April 21, 201412 yr At the moment your <div class="sidebar"></div> is inside your <div class="inner">. If yo moved it out like this - <div id="content_box"> <div class="sidebar"></div> <div class="inner"> <div class="content"></div> </div><!-- close the .inner div --> </div><!-- close the #content_box div --> It would pull it outside the restricted width of the class inner div. However; you really need to look at using HTML5 tags such as <section><article><aside> etc for semantic reasons instead of the 'meaningless' <div> for everything.
Create an account or sign in to comment