Forum Replies Created

Viewing 15 replies - 1 through 15 (of 59 total)
  • Plugin Author krut1

    (@krut1)

    Hi. Yes, it is compatibel.

    Thread Starter krut1

    (@krut1)

    Hey guys, do you have a solution?

    Thread Starter krut1

    (@krut1)

    Why did you close this issue? This problem is still not resolved. Please fix at first. Description of the problem is in the preview message.

    Thank you.

    Thread Starter krut1

    (@krut1)

    The error was only one time. Yes, please close.

    Thread Starter krut1

    (@krut1)

    Thanks!

    Thread Starter krut1

    (@krut1)

    Hey people. Do you have any news for us?

    Thread Starter krut1

    (@krut1)

    Thanks!

    Thread Starter krut1

    (@krut1)

    Thank you. We will wait for the fix.

    Thread Starter krut1

    (@krut1)

    I have found the problem in your code. I try to explain it you. Look please in the function get_filtered_term_product_counts. There is this part of code:

    // Maybe store a transient of the count values.
    $cache = apply_filters( 'woocommerce_layered_nav_count_maybe_cache', true );
    if ( true === $cache ) {
      $cached_counts = (array) get_transient( 'wc_layered_nav_counts_' . sanitize_title( $taxonomy ) );
    } else {
      $cached_counts = array();
    }
    
    if ( ! isset( $cached_counts[ $query_hash ] ) ) {
      $results  = $wpdb->get_results( $query, ARRAY_A ); // @codingStandardsIgnoreLine
      $counts   = array_map( 'absint', wp_list_pluck( $results, 'term_count', 'term_count_id' ) );
    
      $cached_counts[ $query_hash ] = $counts;
      if ( true === $cache ) {
        set_transient( 'wc_layered_nav_counts_' . sanitize_title( $taxonomy ), $cached_counts, DAY_IN_SECONDS );
      }
    }

    If we have the widget Filter Products by Attribute for taxonomy color (for example), then you will save in transient wc_layered_nav_counts_pa_color this array:

    Array(
      '7b067ca573b7add02bb674547eaeba92' => [46 => 2, 47 => 2]
    )

    ATTENTION! If we have a search function on our website, and our user looks for something, then this array will be increased:

    Array(
      '7b067ca573b7add02bb674547eaeba92' => [46 => 2, 47 => 2],
      'd41d8cd98f00b204e9800998ecf8427e' => [46 => 1, 47 => 0]
    )

    At the request of the next user, it will be increased again:

    Array(
      '7b067ca573b7add02bb674547eaeba92' => [46 => 2, 47 => 2],
      'd41d8cd98f00b204e9800998ecf8427e' => [46 => 1, 47 => 0],
      '74be16979710d4c4e7c6647856088456' => [46 => 1, 47 => 0]
    )

    And each time there is an update of this transient for the next 24 hours:

    set_transient( 'wc_layered_nav_counts_' . sanitize_title( $taxonomy ), $cached_counts, DAY_IN_SECONDS );

    Thus, the transient will never become outdated (because users use the search at least once a day) and its size will only grow.

    • This reply was modified 4 years, 5 months ago by krut1.
    Thread Starter krut1

    (@krut1)

    Hi, thanks for your answer. As you can see, the problem happens in WC_Widget_Layered_Nav->get_filtered_term_product_counts. Or rather, in the process of storing the query result in the cache: set_transient( 'wc_layered_nav_counts_' . sanitize_title( $taxonomy ), $cached_counts, DAY_IN_SECONDS );.

    The result of the query should be an array such this:

    Array
    (
        [46] => 2
        [47] => 2
        [48] => 2
        [58] => 1
    )
    

    right?

    How can be there this:

    [17-Jun-2020 07:24:24 UTC] WordPress-Datenbank-Fehler Got a packet bigger than 'max_allowed_packet' bytes für Abfrage UPDATE 458_options SET option_value = 'a:67395:{i:0;b:0;s:32:\"7b067ca573b7add02bb674547eaeba92\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"d6bada27888dbe49999720c37404bfa7\";a:0:{}s:32:\"eeceb1d0b7618678813d0ee468efeda4\";a:0:{}s:32:\"dbd9941eef4978fa293ba704d305037c\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"88885b436ffb52642c3597348d659d3b\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"f40a1c63d1daffbcef62cf25ebcaf993\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"d7b5aedde99a4a2add046065565ee0e3\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"2f2f970e3d25b004b2319caa96bb697f\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"1d65e6190441581ef8d9cfa24835fbe9\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"fc6beb150f52f9ca773559002281ad5c\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"e65d0c7eb8efd3b83e3e2281babfc6fe\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"422189d5401122809ff27c76be64ce97\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"e14e2fe1899d369a097423b8ef00ce37\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:122;i:1;i:123;i:1;i:124;i:1;i:125;i:1;i:126;i:1;i:127;i:1;i:128;i:1;i:129;i:1;i:130;i:1;i:131;i:1;i:132;i:1;i:133;i:1;i:134;i:1;i:135;i:1;i:136;i:1;}s:32:\"5f1f86bc9649f25c63938b131c40b00f\";a:20:{i:117;i:1;i:118;i:1;i:119;i:1;i:120;i:1;i:121;i:1;i:12 ... WHERE option_name = '_transient_wc_layered_nav_counts_pa_brand';

    It looks not like an array, or?

    • This reply was modified 4 years, 5 months ago by krut1.
    • This reply was modified 4 years, 5 months ago by krut1.
    • This reply was modified 4 years, 5 months ago by krut1.
    Thread Starter krut1

    (@krut1)

    Thanks!

    Thread Starter krut1

    (@krut1)

    The problem is here: /wordpress/wp-content/plugins/smartcrawl-wordpress-seo/includes/tools/onpage.php:232

    Look on this function: smartcrawl_canonical(): there is such code:

    ...
    // Set decent canonicals for homepage, singulars and taxonomy pages.
    $canonical = $this->get_canonical_url();
    ...
    if ( ! empty( $canonical ) ) {
      $this->print_html_tag( '<link rel="canonical" href="' . esc_attr( $canonical ) . '" />' . "\n" );
    }
    ...

    The function get_canonical_url can return not only string, but also bool|mixed|string|WP_Error (according your documentation).

    The right check is: if ( is_string( $canonical ) && ! empty( $canonical ) ) { instead of simple if ( ! empty( $canonical ) ) {.

    Please fix ??

    Thread Starter krut1

    (@krut1)

    thanks a lot!

    Thread Starter krut1

    (@krut1)

    If you need Stack trace:

    [14-Jun-2020 22:55:10 UTC] PHP Fatal error:  Uncaught Error: Call to a member function needs_payment() on bool in /wordpress/wp-content/plugins/woocommerce-germanized/includes/class-wc-gzd-checkout.php:417
    Stack trace:
    #0 /wordpress/wp-content/plugins/woocommerce-germanized/includes/class-wc-gzd-emails.php(715): WC_GZD_Checkout->add_payment_link()
    #1 /wordpress/wp-includes/class-wp-hook.php(289): WC_GZD_Emails->email_pay_now_button()
    #2 /wordpress/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters()
    #3 /wordpress/wp-includes/plugin.php(478): WP_Hook->do_action()
    #4 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/templates/woo/emails/email-order-details.php(142): do_action()
    #5 /wordpress/wp-content/plugins/woocommerce/includes/wc-core-functions.php(251): include('/var/www/wireca...')
    #6 /wordpress/wp-content/plugins/woocommerce/includes/class-wc-emails.php(419): wc_get_template()
    #7 /wordpress/wp-includes/class-wp-hook.php(287): WC_Emails->order_details()
    #8 /wordpress/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters()
    #9 /wordpress/wp-includes/plugin.php(478): WP_Hook->do_action()
    #10 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/templates/woo/emails/customer-processing-order.php(45): do_action()
    #11 /wordpress/wp-content/plugins/woocommerce/includes/wc-core-functions.php(251): include('/var/www/wireca...')
    #12 /wordpress/wp-content/plugins/woocommerce/includes/wc-core-functions.php(270): wc_get_template()
    #13 /wordpress/wp-content/plugins/woocommerce/includes/emails/class-wc-email-customer-processing-order.php(113): wc_get_template_html()
    #14 /wordpress/wp-content/plugins/woocommerce/includes/emails/class-wc-email.php(540): WC_Email_Customer_Processing_Order->get_content_html()
    #15 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/includes/class-kadence-woomail-preview.php(727): WC_Email->get_content()
    #16 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/includes/class-kadence-woomail-preview.php(767): Kadence_Woomail_Preview::get_preview_email()
    #17 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/preview.php(40): Kadence_Woomail_Preview::print_preview_email()
    #18 /wordpress/wp-content/plugins/kadence-woocommerce-email-designer/includes/class-kadence-woomail-preview.php(200): include('/var/www/wireca...')
    #19 /wordpress/wp-includes/class-wp-hook.php(287): Kadence_Woomail_Preview->set_up_preview()
    #20 /wordpress/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters()
    #21 /wordpress/wp-includes/plugin.php(544): WP_Hook->do_action()
    #22 /wordpress/wp-includes/class-wp.php(388): do_action_ref_array()
    #23 /wordpress/wp-includes/class-wp.php(735): WP->parse_request()
    #24 /wordpress/wp-includes/functions.php(1274): WP->main()
    #25 /wordpress/wp-blog-header.php(16): wp()
    #26 /wordpress/index.php(17): require('/var/www/wireca...')
    #27 {main}
      thrown in /wordpress/wp-content/plugins/woocommerce-germanized/includes/class-wc-gzd-checkout.php on line 417
    • This reply was modified 4 years, 5 months ago by krut1.
    Thread Starter krut1

    (@krut1)

    Thanks a lot. We will update your plugin!

Viewing 15 replies - 1 through 15 (of 59 total)