Support » Plugin: Jetpack by WordPress.com » Customizing Jetpack related posts post types

  • I have a site with a custom post type and I would like to have related posts so that:

    * only related Posts show on Posts (i.e. the WordPress Posts post type)
    * only related custom-post-type show on pages for that post type

    I see that I can add a custom post type via the rest_api_allowed_post_types filter, but the example isn’t clear whether or not I’ll only get related posts of any given post type for that post type.

    Will related posts only show related posts of the same post type of the page being viewed, or is there a way to achieve that?

    Thanks,

    mark.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Jeremy Herve

    (@jeherve)

    Jetpack Mechanic 🚀

    Will related posts only show related posts of the same post type of the page being viewed, or is there a way to achieve that?

    By default, Related Posts are limited to posts belonging to the same post type as the original post:

    • You’ll only get posts when looking at Related Posts for a Post.
    • You’ll only get Custom Post Types when looking at Related Posts for a Custom Post Type (after you’ve enabled Related Posts for that post type, as you figured out already).

    I hope this clarifies things a bit.

    Thank you very much – that’s clear!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Customizing Jetpack related posts post types’ is closed to new replies.