WordPress.org

Ready to get started?Download WordPress

Forums

Relevanssi - A Better Search
[resolved] Duplicate custom post types (4 posts)

  1. Andrzej
    Member
    Posted 5 months ago #

    Hi Mikko,

    We use 'The Events Calendar' Pro to create reoccurring events with the same title, content but different dates. Is there some way to post-process search results to show just the latest event (custom post type) and skip older events? Perhaps using your 'hook' API?

    Otherwise, I'm open to seeing this feature in Relevanssi Premium.

    Thanks for the nicely done plugin. Cheers.

    https://wordpress.org/plugins/relevanssi/

  2. Mikko Saari
    Member
    Plugin Author

    Posted 5 months ago #

    You could use the relevanssi_hits_filter hook. It lets you process all the search results. You can go through the results (it's a simple array of post objects) and remove the older events from the array.

  3. Andrzej
    Member
    Posted 5 months ago #

    Mikko,

    Thank you for directing me to that filter. After a quick peek at your user-manual, I have a good sense of how to filter my calendar event post types.

    BTW, is the relevanssi_hits_filter only available to premium subscribers?

  4. Mikko Saari
    Member
    Plugin Author

    Posted 5 months ago #

    No, the filter is available in both versions of the plugin. There aren't many Premium-only filters, and those relate to Premium features, not generic search features.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags