am trying to develop my own wordpress custom,am having problems trying to add a sidebar float left e.g something like Twenty Sixteen theme. please help am still learning. Thank you.
1 Answer
You would do something like this with your CSS. Setting a fixed height and whatnot is only for example purposes:
#content {
background: brown;
width: 75%;
height: 500px;
float: left;
}
#sidebar {
background: gray;
width: 25%;
height: 500px;
float: left;
}
<div id="content"></div>
<div id="sidebar"></div>
-
-
@Mulusa Pupe The more specific you make your question, the easier it is to assist. Edit your question to include the basics of what you're working with if the above example is of no use to you. Commented Feb 22, 2020 at 19:42
-
Thanks for your reply, i started editing the codes given above i managed to work out something out, but i think the height is giving me problems with scattered content.Please Help Commented Feb 22, 2020 at 20:36
-
@MulusaPupe Do not define a height. The content will make it scale. If you need both the content and sidebar containers to be the same height for visual reasons, you can use flexbox. Note that using flexbox will require additional testing in Internet Explorer, if you care about those users, as its implementation of it is buggy. Commented Feb 22, 2020 at 20:45
-