WordPress.org

Ready to get started?Download WordPress

Forums

Yet Another Related Posts Plugin (YARPP)
[resolved] [Plugin: Yet Another Related Posts Plugin] Making YARPP caching feature work for custom post types (4 posts)

  1. binfil
    Member
    Posted 1 year ago #

    I was using yarpp_related( ... ) option in order to show the related posts for a custom post type. I realized that the items displayed were not going through the caching mechanism.

    I could not find a clear/simple explanation elsewhere so I am posting the solution I came up with.

    So, If you want to make the custom post types work with caching:

    Add 'yarpp_support' => true to your functions.php

    register_post_type('myCustomPostType', array(
        ........
        ........
        ........
         'yarpp_support' => true
        ));

    Now you will see your custom post type name in the settings section -> "post types considered"

    In your template file, use

    <?php related_entries(); ?>

    Voila!

    http://wordpress.org/extend/plugins/yet-another-related-posts-plugin/

  2. binfil
    Member
    Posted 1 year ago #

    resolving this to avoid misunderstandings...

  3. aidecms
    Member
    Posted 1 year ago #

    Hi, I'm trying ti add a related entries function into each bbpress topic.

    would you please let me know How to edit my function file ? or bbpress.php file

    thank you very much

  4. mitcho (Michael Yoshitaka Erlewine)
    Member
    Plugin Author

    Posted 1 year ago #

    @aidecms I see you created a new thread, so let's discuss that there. Please don't post in multiple threads.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic