Title: Code Changes
Last modified: August 18, 2016

---

# Code Changes

 *  [Kate](https://wordpress.org/support/users/katie1/)
 * (@katie1)
 * [20 years, 3 months ago](https://wordpress.org/support/topic/code-changes/)
 * Hi All,
    Can someone please help me with this?
 * If this code can pull all posts by author on a single.php page in the sidebar:
   `
   <ul>` `<?php query_posts('cat=7&author=' . $post->post_author . '&order=ASC&showposts
   =-1'); ?>` `<?php if(have_posts()) : while(have_posts()) : the_post(); ?>` `<
   li>` `<a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>` `</li>` `
   <?php endwhile; endif; ?>` `</ul>`
 * Can someone please advise what changes I’ll need to make to this code so I can
   display ALL POSTS as Links in the sidebar on a single.php that relate to all 
   posts in a given category regardless of which category/single.php is being displayed?
 * Hmmm. I hope that makes sense.
 * Ta muchly
    Kate

The topic ‘Code Changes’ is closed to new replies.

 * 0 replies
 * 1 participant
 * Last reply from: [Kate](https://wordpress.org/support/users/katie1/)
 * Last activity: [20 years, 3 months ago](https://wordpress.org/support/topic/code-changes/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
