No sidebar on main blog page


  • No sidebar on main blog page
    Viewing 5 posts - 1 through 5 (of 5 total)

  • leojez


    I have used your template for the blog with sidebar to create my blog section.

    The sidebar showed until in Settings –> Reading I set the following:

    – Static page
    – Front page: Home
    – Posts page: Blog

    Then the sidebar disappears. If I change Post page back to “Select” the sidebar comes back.

    On the blog page itself I have selected right-sidebar and the correct sidebar.

    Incidentally, the posts actually show the sidebar.

    Any ideas on getting the sidebar to show on the main page?



    Hello Leojez,

    Setting the blog page to be a template is different from setting the Posts Page
    the blog template calls the file circleflip/templates/template-blog.php
    while the Posts Page calls the circleflip/index.php

    There is a rather dirty option to add the sidebar to the index.php page
    change the line
    <section class="span12">
    to be
    <section class="span9">
    and add after the line
    </section><!-- #primary -->
    the following
    <aside class="span3">
    <?php dynamic_sidebar( 'blog' ); ?>

    where ‘blog’ is the sidebar name



    Thanks Omar!

    That is almost perfect. There seems to be some padding missing which I can’t seem to figure out. As you can see, the main blog page now has the sidebar:

    but it isn’t padded like the individual blog pages:

    How can I fix this please?


    Hello Leojez,

    Sorry for the untimely response,
    and sorry for the miss on that padding

    in the code you edited before, make the last bit like
    <section class="span3">
    <aside class="sidebar right">
    <?php dynamic_sidebar( 'blog' ); ?>



    Thanks Omar, worked perfectly!

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘No sidebar on main blog page’ is closed to new replies.