• I’m currently working on a site that will be an online shop selling CDs/vinyl for a small record label.

    I’ve created a category structure along the lines of the following:

    Catalogue (default category)
    – Artist 1
    – Artist 2
    – Artist 3 etc
    Format
    – CD
    – 7″ Vinyl etc
    Special Offers
    – 50% off
    – 10% off etc

    So you see that an album will be in multiple categories.

    For example: Artist 1, CD, 10% off

    Now on the sidebar.php I’d like to be able to put ‘Other items by the same artist’. This would pull out, say 4 items
    from the same artist category as the item being viewed (but not show anything from the other categories the post is in)

    I really cant think of a way to do this. Can anybody help me out?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Is “Artist1” a subcategory of Catalog? I mean if it’s a category, then probably you can use any of the solutions suggested in this thread by katie1 and Kafkaesqui.
    http://wordpress.org/support/topic/57698?replies=4

    Thread Starter endofamnesia

    (@endofamnesia)

    Yes all artists are subcategories of Catalgoue.

    What’s puzzling me how I would display the lastest posts from
    only the artist category they are in…on individual posts.

    If I just show latest posts that are children of ‘Catalogue’ then it wont show only the latest posts from Artist 1, it would display any posts from artist 2, artist 3, etc.

    Show only the latest posts from the category ‘artist1’.

    Thread Starter endofamnesia

    (@endofamnesia)

    Surely if I put code that says ‘show only latest posts from artist1’ on the sidebar then for each post it will only show the latest post in artist1.

    What i really need is that to dynamically change…so youre viewing a post that has been put in

    artist1, CD Album, 10% off

    then the side bar shows ‘other posts in artist1’ category.
    Of if youre looking at a post that has been put in

    artist26, Vinyl album

    then the sidebar shows ‘other posts in artist26’ category.

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

The topic ‘Posts in multiple categories problem’ is closed to new replies.