Forums Forums Search & Filter Pro Site crashed after updating to 2.0.1

Viewing 10 posts - 11 through 20 (of 20 total)
  • Ross Moderator
    #37898

    Hey John

    The WooCommerce display method is for displaying on your shop.

    S&F asks WooCommerce what the shop URL is, and then redirects the search there.

    If you want to use any other URL then you are correct, you will likely need to use another display method.

    RE your issues, did you check the upgrade notes?

    https://www.designsandcode.com/documentation/search-filter-pro/2-0-upgrade-notes/

    Where you have:

    if ($searchandfilter->is_valid_form())

    I think you should replace this with:

    if($searchandfilter->active_sfid())

    All instances of $sf_form_data need to be renamed to $searchandfilter, and possibly some functions have been renamed which are outlined in the upgrade notes.

    Hope that helps, let me know how you get on.

    Thanks

    Anonymous
    #37944

    Hello Ross.

    First I want to say thank you for helping me.

    I added this:

    add_filter(‘body_class’,’add_body_class_to_search_filter’);
    function add_body_class_to_search_filter($classes) {

    global $searchandfilter;
    if($searchandfilter->active_sfid())

    {
    $classes[] = “tax-product_cat archive woocommerce woocommerce-page alt-style-default boxed-layout two-col-right width-930 two-col-right-930”;
    }
    // return the $classes array
    return $classes;
    }

    and it is still crashing my staging site. Anything else that needs to be changed?

    Thanks

    Ross Moderator
    #37946

    So the plugin is already updated, and you have the above code and its crashing your site?

    Thats odd, doesn’t look like anything wrong with that piece of code.

    Could be some other code.

    Enable WP_DEBUG to get more info on what the error message is, and then we can go from there.

    Thanks

    Anonymous
    #38062

    Alright, I enabled it.

    And when the site breaks after adding the code to the functions.php of my theme this is the error I see:

    Warning: mysqli_real_connect(): Headers and client library minor version mismatch. Headers:50544 Library:50629 in /var/www/dogloverstore/staging-site/wp-includes/wp-db.php on line 1488

    That is all I see though, nothing else, just a white screen.

    Thanks

    Ross Moderator
    #38065

    Thats very strange, seems to be a DB error of some kind.

    What happens, when you comment out all the custom S&F code completely?

    Can you then also disable S&F to ensure it is in fact S&F generating this error?

    Thanks

    Anonymous
    #38097

    When I comment out the code in the functions.php file the warning stays the same but the site loads normally. If I remove the commenting out, the site breaks and the warning still exists.

    Also, when I deactivate S+F that warning still persists, so it doesn’t seem like S+F is causing that warning but it is breaking my site when the code is added to the functions.php file.

    Thanks

    Ross Moderator
    #38102
    This reply has been marked as private.
    Anonymous
    #38134

    All set, Ross, I sent the email.

    Thanks!

    Ross Moderator
    #38439

    Jsut replied via email, should all be sorted 🙂

    Anonymous
    #38457

    That worked Ross.

    Thank you so much!

    John

Viewing 10 posts - 11 through 20 (of 20 total)