Support » Fixing WordPress » Adding sidebar.php to single.php

  • Hi. I tried the solutions I could find regarding adding sidebar to single.php but nothing worked correctly. I want to put the sidebar as it is on the index.php info the single story pages. Every time I try, it drops it down under the story content.

    I believe this should be simple. The first step adding <?php get_sidebar(); ?> before the footer as in index.php, but there must be something else. CSS? DIV classes?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Michael Torbert

    (@hallsofmontezuma)

    WordPress Virtuoso

    This is a CSS and/or DIV issue. It depends on your layout. What is the link to your site?

    Hi. Sorry for a delayed response. The site I’m trying to add a sidebar to for the content pages is hd-report.com. Any insight would be appreciated.

    Don’t use the default theme. Get another theme that has the sidebar in every view:
    http://themes.wordpress.net
    What could be simpler?

    Hi. Thanks. The site is obviously in an evolutionary state – I was hoping to figure out how to do it to eventually create my own theme.

    Tried a few things I found on the forum but what I usually get is a right bar that sits down under the left (main column). I suppose this a CSS adjustment to allow the sidebar to align vertically to the top?

    Just do a quick search for “sidebar down” or “sidebar down IE” and you will find hundreds of posts… all with the same simple solution.

    Just to close this topic, there are as the moderator says hundreds of posts on “sidebar down”. What I have found is there are issues with IE and if there are any bits of broken code it will definitely break your page.

    That aside, if you are just looking to change the default 1-column layout of the single posts to a 2-column like the homepage, do the following.

    Go to sidebar.php and change “widecolumn” class to “narrowcolumn” as is on the index.php. Ad <?php get_sidebar(); /> above the footer call and you should be good to go.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Adding sidebar.php to single.php’ is closed to new replies.