• Resolved mindykatzen

    (@mindykatzen)


    Helllo,

    This is a spectacular plugin. All plugins and WP/Woo are updated to the current version.
    We are currently updating to HPOS and have the Woo > Settings > Advanced > Features set as follows (yes, all orders are synchronized):

    1. Enabled: “High-performance order storage (recommended)”
    2. Not checked: “Enable compatibility mode (synchronizes orders to the posts table).”

    When we enter something to search on the development site, nothing is returned. Our live site without HPOS is working fine. This is on a development site restricted by IP, so the url is not here.

    I see no error in the browser developer’s panel indicating the jquery/javascript/ajax is okay.

    The wp-content/debug.log error thrown every time a character is entered (after the minimum number of chars) is as follows:

    [17-Jul-2024 22:33:16 UTC] PHP Fatal error:  Uncaught Error: Call to undefined function DgoraWcas\mb_strtolower() in wp-content/plugins/ajax-search-for-woocommerce/includes/Helpers.php:695

    Stack trace:

    #0 wp-content/plugins/ajax-search-for-woocommerce/includes/Helpers.php(666): DgoraWcas\Helpers::normalizePhrase('white water lil...')

    #1 wp-content/plugins/ajax-search-for-woocommerce/includes/Engines/WordPressNative/Search.php(245): DgoraWcas\Helpers::calcScore('white water lil...', ''White Delight'...')

    #2 wp-content/plugins/ajax-search-for-woocommerce/includes/Engines/WordPressNative/Search.php(724): DgoraWcas\Engines\WordPressNative\Search->getSearchResults('white water lil...', true, 'product-ids')

    #3 wp-includes/class-wp-hook.php(324): DgoraWcas\Engines\WordPressNative\Search->overwriteSearchPage(Object(WP_Query))

    #4 wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, Array)

    #5 wp-includes/plugin.php(565): WP_Hook->do_action(Array)

    #6 wp-includes/class-wp-query.php(1881): do_action_ref_array('pre_get_posts', Array)

    #7 wp-includes/class-wp-query.php(3824): WP_Query->get_posts()

    #8 wp-includes/class-wp.php(696): WP_Query->query(Array)

    #9 wp-includes/class-wp.php(816): WP->query_posts()

    #10 wp-includes/functions.php(1336): WP->main('')

    #11 wp-blog-header.php(16): wp()

    #12 index.php(17): require('/...')

    #13 {main}

      thrown in wp-content/plugins/ajax-search-for-woocommerce/includes/Helpers.php on line 695

    Thank you for such a wonderful and useful plugin! I look forward to a solution.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Kris

    (@c0nst)

    Hi @mindykatzen!

    The error Uncaught Error: Call to undefined function DgoraWcas\mb_strtolower() indicates that the mb_strtolower function is not defined in your PHP environment. This issue is likely caused by the missing mbstring extension, which is required to use mb_* functions.

    To fix that issue you need to install the mbstring extension:

    1. On the Linux servers, you can install it using the command: 
      sudo apt-get install php-mbstring
    2.  On the Windows servers, ensure that your php.ini file contains the line:
       extension=php_mbstring.dll

    After installing it remember to restart your server. Then, the mb_strtolower function should be available, and the error should be resolved.

    If you’re not entirely sure how to do this, you might want to ask your hosting support for assistance.

    Regards,
    Kris

    • This reply was modified 2 months ago by Kris.
    • This reply was modified 2 months ago by Kris.
    Thread Starter mindykatzen

    (@mindykatzen)

    Thank you, Kris. You were correct and we now have the mb_strtolower. Odd, though, I was working for months under the same system until now.

    Make it a wonderful day! You deserve it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.