Group Details Private

administrators

Member List
  • RE: When will the search by publication date feature be available?

    Hi @Simply_Friend

    Thank you for the question. Actually it's not planned to be added to the plugin core, because this feature (search by date FROM - TO) is already implemented in WP Native search (in WP_Query()).

    So you can search with date using WP_Query parameter date_query.

    Here is the topic: https://developer.wordpress.org/reference/classes/wp_query/#date-parameters

    Another question is if you want date picker fields to be added next to the text query field in the search widget.

    This is fairly easy to do for the average WP developer. There are probably some visual constructors to do this, but I can’t recommend anything here - if you find a solution, please write. It will be useful for other users.

    We don't plan to add a search form builder to the core functionality of WPFTS because we don't want to compete with Elementor / Beaver Builder / Visual Builder etc etc, although we will probably do a detailed tutorial on how to use the builders to make a search widget with additional fields.

    Hope this helped you.

    Thanks!

    posted in Frequently Asked Questions
  • Slow search on a site based on Divi Theme

    In fact, the problem can sometimes be caused not by a slow search by WPFTS plugin or even by a slow generation of Smart Excerpts. The search slowdown was caused by a bug (or flaw) in the code of the Divi theme itself.

    Let's get closer to the code. So, one of the clients contacted us with a complaint that some search requests took too long to process (about 10-12 seconds), which is extremely non-standard for WPFTS even with 500k records, and the client at that time had less than 1000 records. The problem was detected on WPFTS Pro v2.51.212.

    After spending several hours deeply studying the code, we found out that due to a flaw in the code of the Divi Theme, post previews are generated anew each time when displaying search results, while logically they should be generated only once and then used.

    There is indeed such a check in the code, but it only works for those images that are smaller in size along one of the axes (height or width). If the image is larger than the target size of the preview, then the code for checking the presence of an already generated preview is simply not called, and the preview is generated again.

    This spends 1-2 seconds for each post in the output results, which, with a number of 10 posts, gives a noticeable slowdown of 10-15 seconds.

    Below we have attached a new version of the Divi Theme file which is suitable for version 4.25.2. We have already reported the bug to the authors of this topic, so we hope that it will be fixed in future versions.

    We hope this article helped you.
    DIVI_THEME_FIX.ZIP

    posted in Recipes and Known Solutions
  • RE: There are no results in the search

    This bug (definitely a bug!) was fixed in version 1.68.232
    We made "ident" field in the new wpftsi_irules table shorter (limited from 255 to 130) to avoid VARCHAR index length overflow.

    Thanks, @lostconcerts !

    posted in Bugs and Fixes
  • RE: There are no results in the search

    HI @lostconcerts

    Thank you for detailed information. Yes, I understand the issue now. The wpftsi_irules table was just not created on version update. The reason WHY it was not created. We need to understand that.

    Do you say you cleared error.log or you have a backup?
    I think we need to find the very first error where this database table should be created.

    Do you think you can activate the plugin again and then send me error.log for analyze?

    Thanks.

    posted in Bugs and Fixes
  • RE: There are no results in the search

    Hi @lostconcerts

    I have read your message and would say it's not clear what happen yet. Did you try to rebuild the index? Recently we updated the core of WPFTS, so it can be a reason, some incompatibility with your website.

    But it's all solvable.

    posted in Bugs and Fixes
  • [Solved] How to fix "Home > Results for ..." issue for Divi

    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.

    posted in Bugs and Fixes
  • RE: Indexing failure

    Hi @harald-b

    I sent a private message for you.

    Please check.

    Let me know if you still have any issues. Thanks!

    posted in Bugs and Fixes
  • RE: WPFTS does not index files NOT uploaded with Media Library

    Hi @Graham

    Thanks for your question. Let me ask you one more clarifying question before I can offer a solution.

    You plan to use the widget for general site-wide search, right? If so, and in this case, if the information is found in one of these files that are listed in your example, then what exactly should be displayed on the search results page? And in this case, where should the user go when he clicks on the title of the search results element?

    posted in Recipes and Known Solutions
  • RE: how to add buttons to the search engine

    @guarani23 Can you send me access to your website to the private messages? I can make a code, it's really simple.

    posted in Frequently Asked Questions
  • RE: how to add buttons to the search engine

    Hi @guarani23

    So, you want these buttons to be an alternative way to enter respective letters into the search string, right?

    For example, if I want to enter the word “NIÑO”, but I have no such letters on the keyboard, I can enter “NI” and then press the “Ñ” button above and it appears in the search box. Is it correct?

    In this case you could add a very simple javascript to the page that will catch button clicks and copy letters to the input text.

    Do you need me to help you with this js code?

    Thanks.

    posted in Frequently Asked Questions