foresthero
New Member
I am trying to create a system within my templating where if I put content in the "sidebars" then the sidebar will show and the main window content will be moved appropriately. If there is no content in the sidebar then it wont show.\[code\] <div id="newcontainer"> <div id="content"> <div id="sidebar-left"> {% block left_sidebar %} {% endblock%} </div> <div id="sidebar-right"> {% block right_sidebar %} {% endblock%} </div> <div id="col-main"> {% block content %} {% endblock%} </div> </div></div>\[/code\]This is how far I have got with other users help:JSFIDDLE LINKHowever, as you can see I have put no content in the left column, but still the padding shows up! This is what I dont want, when there is no content in the sidebar I want it to disappear completely. What options do I have for this? I dont want to put the padding on the center box because when there are no sidebars I will be left with the padding on the center box still.