Currently my ‘sidebar.php’ contains:
<?php
$category_description = category_description();
if ( ! empty( $category_description ) )
echo '<div class="archive-meta">' . $category_description . '</div>';
/* Run the loop for the category page to output the posts.
* If you want to overload this in a child theme then include a file
* called loop-category.php and that will be used instead.
*/
get_template_part( 'loop', 'category' );
?>
and the loop takes place in ‘loop-category.php’
I think what is happening is, because I’m calling the same loop as the category page but inside of a post it can only see that post and does not output the rest. However I have no idea how to instruct the loop to call the entire category from inside a post.
Although I may be entirely wrong, I’m currently clueless.