WordPress.org

Forums

Event Organiser
[resolved] Use event post with YARPP (2 posts)

  1. jbo.ciel
    Member
    Posted 1 year ago #

    Hello,

    I would like to add event into the Yet Another Related Posts Plugin.

    As i read:

    the attribute yarpp_support must be set to true on the custom post type when it is registered

    Is there anyway to add easily the attribute after the registration in my function.php?

    Thank you in advance for the help,
    jB

    http://wordpress.org/plugins/event-organiser/

  2. jbo.ciel
    Member
    Posted 1 year ago #

    Hello,

    I found a way on a blog to add all custom posts:

    function add_yarpp_support_to_post_types($post_type, $args) {
        global $wp_post_types;
        $args->yarpp_support = true;
        $wp_post_types[$post_type] = $args;
    }
    add_action('registered_post_type', 'add_yarpp_support_to_post_types', 10, 2);

    So i close the topic for know.

    jB

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Event Organiser
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic