Get WPFTS Pro today with 25% discount!

No valid search resulds, whats wrong?


  • Hello,

    i have some problems running the WP Fast Total Search plugin successfully.

    I have a wordpress site with PODS plugin, which adds some custom entities and custom fields. At first it looks really good, because all the posts are getting indexed. When using the Sandbox tools i can confirm my example post with ID 11802 is getting index. When searching something which is inside the "0" field of that post, it won't return any relevant results. Why is this?

    I attached a screen cap video to show you everything. https://youtu.be/jbkO1a2N6qc

    best Regards


  • Hi,

    i would love to get an answer to that. Am i using the plugin wrong and assuming a functionality it does not have? If you need any additional info about the system please let me know.

    Best Regards


  • Hi @stark

    Thank you for the question!

    I think you know how to deal with PODS custom meta fields because I see that you have created clusters with data in the index, and I think it was achieved by the custom code. That's 80% of the job!

    As I can see your post records are searchable in the Sandbox by words from the "0" cluster (the custom metafield).

    The only problem is you can not get your custom posts shown in the search results on the front page.

    This may be caused by a hook in your theme or custom code that intercepts pre_get_posts or another hook related to WP_Query and adds additional filtering to posts either at the input parameter level (for example, it allows searching only posts with post_type = post, page; or adds additional WHERE conditions directly to the query that is formed in WP_Query). I would advise you to review the code of your custom plugins and theme for such hooks. I also recommended that you disable all plugins that may be related to search for testing. For example, Elastic Press.
    We are not very familiar with the functionality of PODS, it is obviously similar to the ACF plugin in the database, but it probably also adds some conditions to the search.

    The presence of a conflicting hook may also be indicated by the fact that in analytics all queries show either 0 or -1 results, which is incorrect information.

    By the way, could you click on any of the rows in the analytics table and see the query details? That might give us a clue as to why this is happening.

    Also, give me some time - I need to see if The7 theme conflicts with WPFTS.

    Thanks! Let me know if any of the above tips helped you.


  • Hi,

    thanks for your answer. I will check out everything you just said and will come back with the results.

    @EpsilonAdmin said in No valid search resulds, whats wrong?:

    As I can see your post records are searchable in the Sandbox by words from the "0" cluster (the custom metafield).

    I'm not sure if this is correct. Please have a close look @ 00:49 (https://youtu.be/jbkO1a2N6qc?t=49) and notice there are results, but every results has 80% relevance and none of the top results have the searched word inside. There should be the post with ID 11802 in the top result.

    Best Regards


  • Hi @stark

    Could you test posts 22515 and 11804 on the first tab of the Sandbox? I am curious which data were indexed in those posts, may be the SAME data was indexed for all those posts. The same relevance ratio (80%) is very less probably for such amount of posts.

    Also I would see the code you are used to put meta fields to the index. Could you share?

    Thanks!


  • @EpsilonAdmin

    Hi,

    This was a very good idea. We noticed that the indexed words are the same for all indexed posts. However, each post actually contains different text. Could this be a problem with the indexing? Any idea how to fix?

    I will come back later with the shared code, since our developer is not available right now.

    Best Regards


  • Hi @stark

    Yes, as soon as you can show me your custom code for wpfts_index_post hook I think we can detect a problem and fix it.

    Thanks!


  • @EpsilonAdmin

    Hi,

    i just received information, that there is no additional custom code in our wordpress installation regarding the WPFTS plugin. The wpfts_index_post hook has not been added anywhere. I also confirmed that via a search on the filesystem itself.

    root@ubuntu-32gb-nbg1-6:/var/www/html# grep -ir "wpfts_index_post" *
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    wp-content/plugins/fulltext-search/languages/fulltext-search.pot:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search.pot:"<code>wpfts_index_post</code> hook, then this time only the Titles and the "
    wp-content/plugins/fulltext-search/languages/fulltext-search.pot:"<code>wpfts_index_post</code> hook, then this time only the Titles and the "
    wp-content/plugins/fulltext-search/languages/fulltext-search.pot:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search.pot:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    grep: wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.mo: binary file matches
    wp-content/plugins/fulltext-search/languages/fulltext-search-es_ES.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-es_ES.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-es_ES.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-es_ES.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    grep: wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.mo: binary file matches
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"например, если вы изменили обработчик хука <b>wpfts_index_post</b>. Помните, "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"которую вы можете задать с помощью фильтра <b>wpfts_index_post</b>). Вы "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"фильтров, включая хук <code>wpfts_index_post</code>. Укажите ID любой "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    wp-content/plugins/fulltext-search/languages/fulltext-search-ru_RU.po:"создавали свой хук <code>wpfts_index_post</code>, в этот раз будут "
    grep: wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.mo: binary file matches
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"wpfts_index_post</b> Filterfunktion geändert haben. Bitte denken Sie daran, "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"des  <b>wpfts_index_post</b> Filters festlegen können). Sie können jeder "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"wpfts_index_post</code>. Geben Sie die ID irgendeines WordPress-Beitrages "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE_formal.po:"eigenen <code>wpfts_index_post</code> Hook installiert haben, dann werden "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"wpfts_index_post</b> Filterfunktion geändert hast. Bitte denke daran, dass "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:" <b>wpfts_index_post</b> Filters festlegen kannst). Du kannst jeder Gruppe "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"wpfts_index_post</code>. Gib die ID irgendeines WordPress-Beitrages ein, um "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    wp-content/plugins/fulltext-search/languages/fulltext-search-de_DE.po:"<code>wpfts_index_post</code> Hook installiert habst, dann werden jetzt nur "
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk_UA.po:"for example, when you changed custom <b>wpfts_index_post</b> filter function."
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk_UA.po:"which you can define using <b>wpfts_index_post</b> filter). You can assign "
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk_UA.po:"a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress "
    wp-content/plugins/fulltext-search/languages/fulltext-search-uk_UA.po:"wpfts_index_post</code> hook, then this time only the Titles and the main "
    wp-content/plugins/fulltext-search/admin/admin_page.php:                <p>If you didn’t install WPFTS Add-ons and didn’t set up your own <code>wpfts_index_post</code> hook, then this time only the Titles and the main Content of the publications will be included in the index. If you want other data to participate in the search (such as <b>post meta data</b>), now is the time to read the %1s WPFTS Documentation %2s and make the necessary changes.</p>
    wp-content/plugins/fulltext-search/admin/templates/blocks/step3_relevance_box.php:                                      <p class="text-secondary"><i><?php echo wp_kses(__('"Cluster" is a part of post (either title, content or even specific part which you can define using <b>wpfts_index_post</b> filter). You can assign some relevance weight to each of them.', 'fulltext-search'), array('b' => array())); ?></i></p>
    wp-content/plugins/fulltext-search/admin/templates/blocks/control_box.php:                                      <p class="text-secondary"><i><?php echo wp_kses(sprintf(__('Use this button when you need to completely rebuild search index database, for example, when you changed custom <b>wpfts_index_post</b> filter function. Remember that this operation could take a long time. Please refer for %1s documentation %2s for more information.', 'fulltext-search'), '<a href="'.esc_url($wpfts_core->_wpfts_domain.$wpfts_core->_documentation_link).'" target="_blank">', '</a>'), array('b' => array(), 'a' => array('href' => array(), 'target' => array()))); ?></i></p>
    wp-content/plugins/fulltext-search/admin/templates/blocks/index_engine_tester.php:                      <p><?php echo wp_kses(__('Before the data from your posts (pages, meta-fields, etc.) gets into the Search Index, they go through a number of built-in WPFTS filters, including a custom hook <code>wpfts_index_post</code>. Enter the ID of any WordPress record to see what data will come to the Search Index.', 'fulltext-search'), array('code' => array())); ?></p>
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             do_action('wpfts_index_post_start', $this, $post, $is_refresh_raw_cache);
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             $chunks = apply_filters('wpfts_index_post', $chunks, $post, $is_refresh_raw_cache);
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             $chunks = apply_filters('wpfts_index_post_finish', $chunks, $post, $this);
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             do_action('wpfts_index_post_start', $this, $post, $is_refresh_raw_cache);
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             $chunks = apply_filters('wpfts_index_post', $chunks, $post, $is_refresh_raw_cache);
    wp-content/plugins/fulltext-search/includes/wpfts_core.php:             $chunks = apply_filters('wpfts_index_post_finish', $chunks, $post, $this);
    root@ubuntu-32gb-nbg1-6:/var/www/html#
    
    

    It seems the index which has been built just built "out of the box". Any ideas? If you need any additional info, please let me know.

    Best Regards


  • Hi @stark

    Unfortunately, WPFTS does not work with PODS custom fields "from the box", so custom code exists somewhere. I think your developer used another way to add data to the search index.

    We need to ask him or alternatively, I could check your code myself, it should not be too long. In this case please send me admin access to your resource using a private message.

    Thanks.


  • This post is deleted!

Suggested Topics

  • Link URL showing up in search results.

    Bugs and Fixes
    6
    0 Votes
    6 Posts
    139 Views
    EpsilonAdminE

    Hi @jgregory_ca

    Okay, the fix for Avada addon should be ready in a couple of days. Just FYI.

    Thanks!

  • Search doesnt work well

    Bugs and Fixes
    9
    0 Votes
    9 Posts
    777 Views
    E

    @EpsilonAdmin

    I tried to disable all plugin except "Advanced Custom Fields PRO", "Change wp-admin login", and "Max Mega Menu", but th search results are the same.

    I didn't find where I can send you private message, sorry.
    I have just installed Anydesk (never have the chance to use before). How could we process please?

  • Unable to translate "Search" widget

    Bugs and Fixes
    3
    0 Votes
    3 Posts
    741 Views
    R

    I am using the Pro version. My registered email is : sita@cavernas.org.br

  • Add button or menu link to search results

    Bugs and Fixes
    7
    0 Votes
    7 Posts
    1k Views
    EpsilonAdminE

    Hi @melanie-james

    First of all, to see attachment contents in Smart Excerpts with Avada theme you need to implement a small patch, which removes the incompatibility of Avada theme.

    Please read more here
    https://fulltextsearch.org/forum/topic/11/solved-avada-theme-excerpt-do-not-show

  • Sorting of Search Results

    Bugs and Fixes
    5
    0 Votes
    5 Posts
    1k Views
    N

    We have over 1,000 pdf documents on our website, and the most important is our Journal, with 238 editions at present. As an example, a couple of issues of our Journal are here, but they are all similar in structure:
    https://rchs.org.uk/wp-content/uploads/2020/02/Journal-100-Nov-1975.pdf
    https://rchs.org.uk/wp-content/uploads/2020/02/Journal-001-Jan-1955.pdf
    You will see that at the bottom of the second page of Journal 100 is a table of contents for the issue and, if the pdf is saved and then opened in Acrobat Reader, there is an equivalent set of bookmarks. It would help if a search term appearing in the article title (as listed in the table of contents) was given a higher weighting than one in the text of the document, but quite often the term will only occur in the text, and not in the title at all.
    Ideally, we would like the weighting to be based upon articles, but weightings based upon the the whole Journal is acceptable. This is because the articles tend to be on unrelated topics within a Journal, so there is probably little difference between the number of instances of a specific search term within an article, and within its parent document.
    I think it would help me if you could explain, in non-technical terms, how the four weightings operate with WPFTS. I've looked at the TFIDF article on Wikipedia, and understand the basics, but the majority of the article is too technical for me. Perhaps this information could also be added to the WPFTS documentation?
    As a related issue, could WPFTS open the document listed in the search results at the first article page where the search term is found? I realise it might go to the article title instead, and if so that wouldn't really help much.

Be the first to read the news!

We are always improving our products, adding new functions and fixes. Subscribe now to be the first to get the updates and stay informed about our sales! We are not spammy. Seriously.

Join Us Now!

We are a professional IT-team. Many of us have been working in a Web IT field for more than 10 years. Our advanced experience of software development has been employed in the creation of the WordPress FullText Search plugin. All solutions implemented into the plugin have been used for 5 or more years in over 60 different web-projects.

We are looking forward to your comments, requests and suggestions in relation to the current plugin and future updates.

ewm-logo-450

The forum powered by NodeBB | Contributors