David Buckley David Buckley - 5 months ago 10
CSS Question

Sidebar not loading correct place

I am using a theme oxygen theme on wordpress but the sidebar is not showing correct you can see its url here

http://212.159.70.57/karen/product-category/women/

You can see the sidebar is showing to the bottom left I have tried changing the main div containers width to fix it but it does not appear to solve the issue

Answer

The problem is that the container where the products are have a class "row" which gives a 100% width:

<div class="main">
    <div class="laborator-woocommerce shop">
        <div class="row">...</div>
        <div class="codenegar-shop-loop-wrapper">
            <div class="row">...</div>
            <!-- Here is the problem -->
            <div class="row">...</div>
            <!-- Here is the problem -->
            <div class="col-md-3 sidebar-env">...</div>
        </div>
    </div>
</div>

One way to fix this is changing the class to one of the classes of your theme, like this:

<div class="main">
    <div class="laborator-woocommerce shop">
        <div class="row">...</div>
        <div class="codenegar-shop-loop-wrapper">
            <div class="row">...</div>
            <!-- Here is the change -->
            <div class="col-md-9">...</div>
            <!-- Here is the change -->
            <div class="col-md-3 sidebar-env">...</div>
        </div>
    </div>
</div>

Hope this helps you with the problem.