Restore Sidebar to WordPress Twenty-Eleven Single Post

I like the sidebar items (including Google Ad) to appear on the single post pages. The Twenty-Eleven theme (which I’ve used for several years) disabled the sidebar. These two patches restored the sidebar.

In the Theme Editor, go to single.php and add the following:

<?php get_sidebar(); ?>

In a new line just above the footer code at the bottom of the file:

<?php get_footer(); ?>

Next, go to functions.php (Theme Functions) and find the following at the bottom of the file:

add_filter( ‘body_class’, ‘twentyeleven_body_classes’ );

Comment it out and it will force WordPress to stop differentiating between normal and single post pages.

Now I have targeted ads once more! Although this is a pretty bad match…

Hummingbird-Sequence-DNA-advertisement