Home Forums WoodMart support forum Fatal error: Uncaught Error: Unsupported operand types: string

Fatal error: Uncaught Error: Unsupported operand types: string

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #450659

    Cioppi88
    Participant

    After Elementor update my customo layout archive template are destroyed.
    Please take a look to the error log:

    Uncaught Error: Call to undefined function is_shop() in /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-content/themes/woodmart/inc/integrations/woocommerce/template-tags.php:297
    Stack trace:
    #0 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-includes/class-wp-hook.php(308): woodmart_woo_wrapper_start()
    #1 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters()
    #2 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-includes/plugin.php(517): WP_Hook->do_action()
    #3 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-content/themes/woodmart/single-woodmart_layout.php(20): do_action()
    #4 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-includes/template-loader.php(106): include(‘/home/885114.cl…’)
    #5 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/wp-blog-header.php(19): require_once(‘/home/885114.cl…’)
    #6 /home/885114.cloudwaysapps.com/mwagefnprm/public_html/index.php(17): require(‘/home/885114.cl…’)
    #7 {main}
    thrown

    This happens using layout builder on specific archive

    • This topic was modified 1 year, 1 month ago by Cioppi88.
    #450668

    Cioppi88
    Participant

    The problem is related to php 8.0.
    Can you test template with new php version?
    I solved downgrading version to 7.4

    #450734

    Artem Temos
    Keymaster

    Hello,

    Please, upgrade PHP to the latest version you need and disable all 3rd party plugins temporarily so we can check this problem.

    Kind Regards

    #450810

    Cioppi88
    Participant

    It’s a production website and I can estroy the site again.
    Can you test on your hand?

    #450942

    Artem Temos
    Keymaster

    Hello,

    Yes, we tested our theme with PHP 8.0 and 8.1 and didn’t see this error. Maybe it happens because of certain configurations on your website. That is why we need to check it on your end.

    Kind Regards

    #450980

    Cioppi88
    Participant

    Step to reproduce the issue on your hand.
    1- Create a product Attribute and enable option “as archive”
    2- Create a Layout Template for this specific attribute
    3- upload the template attached in order to test my layout
    4- go to this archive and you’ll see fatal error caused from php 8

    #450996

    Artem Temos
    Keymaster
    #451024

    Cioppi88
    Participant

    Try to use your elementor widget to show grid of product and select your attribute to filter product query

    #451067

    Artem Temos
    Keymaster

    You don’t need to set a filter for the product archive element. Products will be filtered automatically based on the attribute page you visited.

    #451083

    Cioppi88
    Participant

    You are right but I give you more context.
    I customize this attribute in order to be hierarchical, then I have more than one product widget with different queries based on child attributes.

    #451282

    Artem Temos
    Keymaster

    Do you mean that you create different layouts per your attribute term? Anyway, we need to see this on your website in order to understand what this problem is caused by.

    Kind Regards

Viewing 11 posts - 1 through 11 (of 11 total)