• Resolved tomorrowboy

    (@tomorrowboy)


    I apologise in advance if this is covered somewhere else.

    I’ve got my site set up so that entries have a sidebar next to them. I would like the sidebar to include links to other entries in the same category.
    So if an entry is posted in category ‘x’ the sidebar will say “read more from category ‘x'” and offer links to some/all of the other entries in that category.

    Thanks,
    Matthew

Viewing 4 replies - 1 through 4 (of 4 total)
  • The samecat plugin should do what you want. You can find it here: http://www.chait.net/index.php?p=87

    Thread Starter tomorrowboy

    (@tomorrowboy)

    It probably should, but I can’t seem to get it to work.
    In the sidebar if I specify what category I want (?php echo list_posts_of_cat(‘x’, 5, 5); ? where x is the category number) it’s no problem.
    But I can’t get it to grab the category number from the entry it’s listed next to. When I use ?php echo list_posts_of_cat(get_the_category(), 5, 5); ? it says “no matching posts”
    I feel like I’m missing something obvious.
    -Matthew

    Thread Starter tomorrowboy

    (@tomorrowboy)

    ah, I just had to use the most recent version of the samecat plugin. I’m foolish.

    🙂 no worries, glad it’s working now.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Listing entries by category’ is closed to new replies.