Adding Custom Fields Search Causes Calendar Widget Errors

Home Forums Calendar Products Events Calendar PRO Adding Custom Fields Search Causes Calendar Widget Errors

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1156517
    KAREN
    Participant

    Hi,

    I have added custom fields to my posts which are unrelated to The Events Calendar using the ACF plugin. I have added fields “Author” and “Source” to my posts. I now need to include these custom fields in the standard WP search. I have tried a couple of plugins and hardcoding this functionality in functions.php to add the fields to the search.

    Every method I have tried — using plugins or code — causes the calendar widget on the side bar to display error messages when I perform a search:

    WordPress database error: [Not unique table/alias: 'wp_postmeta']
    SELECT SQL_CALC_FOUND_ROWS DISTINCT wp_posts.ID FROM wp_posts INNER JOIN wp_postmeta ON ( wp_posts.ID = wp_postmeta.post_id ) INNER JOIN wp_postmeta AS mt1 ON ( wp_posts.ID = mt1.post_id ) LEFT JOIN

    Here are a couple of examples I have tried:

    Search WordPress by Custom Fields without a Plugin

    Relevanssi – A Better Search

    Great software!

    Thanks for your help…

    #1157169
    Josh
    Participant

    Hey Karen,

    Thanks for reaching out to us!

    I did some testing using the following steps:

    1. Relevannsi plugin and Advanced Custom Fields plugins activated
    2. Added a “sample” custom field and updated the Relevanssi settings to index for that particular field
    3. With an Event Calendar within my sidebar, I searched for the value that I placed within a test post of that custom field
    4. The calendar displayed as expected within the sidebar and the associated results showed what I expected for the results.

    As a test here, have you tried following our Testing for Conflicts procedures to ensure there isn’t a conflict occurring here with another plugin or your current theme?

    Let me know if this helps.

    Thanks!

    #1166443
    Support Droid
    Keymaster

    Hey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.

    Thanks so much!
    The Events Calendar Support Team

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Adding Custom Fields Search Causes Calendar Widget Errors’ is closed to new replies.