WordPress.org

Ready to get started?Download WordPress

Forums

Custom field data in search results (3 posts)

  1. roothost
    Member
    Posted 2 years ago #

    Is it possible at all to have custom field data show in the search results?

    I have a site that makes use of a lot of custom fields and post types, and no matter what I do, or what plugin I use, I cannot get the excerpt, or any content, of these custom fields to appear in the search results.

    Happy to post some code up, but first, is there anything obvious I should be doing?

    Currently trying to get this working using the Relevanssi plugin, if that helps.

  2. Mikko Saari
    Member
    Posted 2 years ago #

    Yes, it is possible. Use 'relevanssi_excerpt_content' filter to add the custom field content to the post content.

  3. roothost
    Member
    Posted 2 years ago #

    I have sorted it now. I found a post with a similar query, and now it is working a treat. Thanks for the reply.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags