• Hello,

    I don’t know if it’s possible to do this but I want to get all tne ‘classic’ wordpress article who are linked to my custom post type.
    Let me explain my case. So I have a CPT “Games”. I want to have, when I visit one of the game page of this CPT, the list of all “classic” posts which is about that game. To list them in the view of the game page.
    Or if I am in a ‘classic’ article page view, to get the game related to the news (to display the cover of the game in the sidebar for example)

    I do not know if it’s clear, and sorry for my bad english.

    Thank you for your help.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    I’d link them via a common taxonomy (either categories or a custom taxonomy). Then all of the normal functionality of taxonomies is available.

    Thread Starter lufyl

    (@lufyl)

    Thank you for your quick response Steve.

    It was exactly what I was thinking. But when I started to code it, I had to create the same taxonomy name that my CPT (“Game”). It was, in my opinion, a little redundant.

    But if it’s the best solution i will make it. Thank you.
    So, if I understand, I have to create for exemple a CPT “Game” with the title “Mario Kart” and with the taxonomy “Game” with the term “Mario Kart” ? And for all my article wish speak about “Mario Kart” I have to tag them with the taxonomy “Game” with the term “Mario Kart” ?

    Thank you very much.

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    It depends on what you want. IF the CPT is “game”, then the taxonomy to link a CPT about “mario cart” to posts would be to assign them both to the “mario cart” category.

    Thread Starter lufyl

    (@lufyl)

    Ok I’ll try to do that.
    I’ll create a taxonomy tag non hierechical named ‘Game’ and enable it for classic posts and my CPT “Game”.
    Thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘get list classic posts related to CPT’ is closed to new replies.