Get WPFTS Pro today with 25% discount!

[Solved] How to fix "Home > Results for ..." issue for Divi

Bugs and Fixes
1 1 201 1

  • Since Divi represents breadcrumbs as a part of the post/page content, you can see a strange "Home >> Results for <search term>" text in the each item on the search results page.
    It's annoying. However this is the simple dirty fix for this problem.

    add_filter('wpfts_index_post', function($index, $post)
    {
    	global $wp_query;
    	
    	// Cut breadcrumbs out of the post_content
    	if (is_string($index['post_content']) && (strlen($index['post_content']) > 0)) {
    		if (isset($wp_query->query_vars['s'])) {
    			$subs = '~Home\s+»\s+Results\s+for\s+'.preg_quote($wp_query->query_vars['s']).'~';
    			$index['post_content'] = preg_replace($subs, '', $index['post_content']);
    		}
    	}
    	
    	return $index;
    }, 50, 2);
    

    Simple add this code to the functions.php of your Divi-child theme and this will remove prepend text from search results.

Suggested Topics

  • Link URL showing up in search results.

    Bugs and Fixes
    6
    0 Votes
    6 Posts
    681 Views
    EpsilonAdminE
    Hi @jgregory_ca Okay, the fix for Avada addon should be ready in a couple of days. Just FYI. Thanks!
  • No search results after update

    Bugs and Fixes
    3
    0 Votes
    3 Posts
    329 Views
    EpsilonAdminE
    @ibloom Thank you, this is actually the thing which I would like to recommend you to do.
  • 0 Votes
    2 Posts
    274 Views
    EpsilonAdminE
    Hi @Felipe-Farinho Você pode me dizer qual tema seu site está usando atualmente? Pode haver uma incompatibilidade de tema/WPFTS (e isso é fácil de corrigir). Além disso, para indexar arquivos do WPDM você precisa instalar um complemento simples https://wordpress.org/plugins/wpfts-add-on-for-wp-download-manager/ (não se preocupe se não for atualizado há algum tempo - iremos atualizá-lo em breve). Isso permitirá que o WPFTS veja os arquivos adicionados ao WPDM. Peço também que você compartilhe um link para o seu site - isso agilizará a busca por uma solução. Obrigado!
  • Unable to translate "Search" widget

    Bugs and Fixes
    3
    0 Votes
    3 Posts
    1k Views
    R
    I am using the Pro version. My registered email is : sita@cavernas.org.br
  • "Prevent Direct Access" Plugin

    Bugs and Fixes
    8
    0 Votes
    8 Posts
    2k Views
    N
    Thank you so much. We'll try this, and I'll let you know the results.

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