Update errors - by sociality - on WordPress WooCommerce support

This topic has 14 replies, 3 voices, and was last updated 6 years, 10 months ago ago by Rose Tyler

  • Avatar: sociality
    sociality
    Participant
    June 8, 2017 at 14:30

    Hello,

    I updated both the theme and the woocommerce plugin and I get some errors. Maybe you are aware of it and you can guide me tho solve theme. Of course I can see them only when I have define(‘WP_DEBUG’, true);

    At the home page I see:
    Notice: Trying to get property of non-object in /home/socia582/public_html/dantemen.com/update/wp-includes/class-wp-query.php on line 3750

    At the product page:
    Notice: id was called incorrectly. Product properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/themes/classico/woocommerce/single-product.php’), wc_get_template_part, load_template, require(‘/themes/classico-child/woocommerce/content-single-product.php’), do_action(‘woocommerce_single_product_summary’), WP_Hook->do_action, WP_Hook->apply_filters, call_user_func_array, sociality_remove_addtocart_from_single_product, WC_Abstract_Legacy_Product->__get, wc_doing_it_wrong Please see Debugging in WordPress for more information. (This message was added in version 3.0.) in /home/socia582/public_html/dantemen.com/update/wp-includes/functions.php on line 4138

    Notice: id was called incorrectly. Product properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/themes/classico/woocommerce/single-product.php’), wc_get_template_part, load_template, require(‘/themes/classico-child/woocommerce/content-single-product.php’), do_action(‘woocommerce_single_product_summary’), WP_Hook->do_action, WP_Hook->apply_filters, call_user_func_array, show_email_form, WC_Abstract_Legacy_Product->__get, wc_doing_it_wrong Please see Debugging in WordPress for more information. (This message was added in version 3.0.) in /home/socia582/public_html/dantemen.com/update/wp-includes/functions.php on line 4138

    Notice: id was called incorrectly. Product properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/themes/classico/woocommerce/single-product.php’), wc_get_template_part, load_template, require(‘/themes/classico-child/woocommerce/content-single-product.php’), do_action(‘woocommerce_single_product_summary’), WP_Hook->do_action, WP_Hook->apply_filters, call_user_func_array, sociality_remove_addtocart_from_archive_products, WC_Abstract_Legacy_Product->__get, wc_doing_it_wrong Please see Debugging in WordPress for more information. (This message was added in version 3.0.) in /home/socia582/public_html/dantemen.com/update/wp-includes/functions.php on line 4138

    Notice: WC_Product::get_upsells is deprecated since version 3.0! Use WC_Product::get_upsell_ids instead. in /home/socia582/public_html/dantemen.com/update/wp-includes/functions.php on line 3830

    Notice: id was called incorrectly. Product properties should not be accessed directly. Backtrace: require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.php’), include(‘/themes/classico/woocommerce/single-product.php’), wc_get_template_part, load_template, require(‘/themes/classico-child/woocommerce/content-single-product.php’), woocommerce_upsell_display, wc_get_template, include(‘/themes/classico-child/woocommerce/single-product/up-sells.php’), WC_Abstract_Legacy_Product->__get, wc_doing_it_wrong Please see Debugging in WordPress for more information. (This message was added in version 3.0.) in /home/socia582/public_html/dantemen.com/update/wp-includes/functions.php on line 4138

    Anything I could do about those? The update of the theme was done from 1.7.1 to 1.8

    Thank you in advance.

    13 Answers
    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    June 8, 2017 at 14:55

    Hello,

    Unfortunately, I can’t see your site http://prntscr.com/fhestr. Please check.
    Also, provide wp-admin and FTP access in Private Content.

    Regards,
    Rose Tyler.

    Avatar: sociality
    sociality
    Participant
    June 9, 2017 at 20:17

    Hello,

    You are now able to see it.

    Thank you.

    Please, contact administrator
    for this information.
    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    June 12, 2017 at 14:06

    Hello,

    Sorry for the delay.
    Yu need update DB after WC update http://prntscr.com/fiu7px. Then disable 3-rd party plugins and activate parent theme to check errors.
    Please note that was big woocommerce update, so many elements in the plugin and our theme functionality were changed. So you may need to edit your changes in the child theme to proper work with new versions.

    Regards,
    Rose Tyler.

    Avatar: sociality
    sociality
    Participant
    June 16, 2017 at 17:11

    Hello,

    Thank you for the guidance. I solved most of the issues by recreating the child theme. I still see an error in the homepage. I believe this is caused by the theme cause I used one of the defaults to see if it has to do with a plugin but it disappeared. The error is: Notice: Trying to get property of non-object in /home/socia582/public_html/dantemen.com/update/wp-includes/class-wp-query.php on line 3760

    Any ideas what might that be?

    Thank you very much.

    Please, contact administrator
    for this information.
    Avatar: laranz
    Laranz
    Participant
    June 17, 2017 at 12:12

    Hi,

    I tried to activate the Parent theme and the error goes off. So I think there is something in the Child theme that cause this, can you pass us the Child theme, so that we can check what’s going wrong.

    Let us know,

    Thanks,
    laranz.

    Avatar: sociality
    sociality
    Participant
    June 18, 2017 at 12:39

    Yes,

    Check the private content for ftp credentials.

    Thank you.

    Please, contact administrator
    for this information.
    Avatar: laranz
    Laranz
    Participant
    June 18, 2017 at 21:39

    Hi,

    I checked your child theme’s functions.php and in that you’re using is_shop() inside the pre_get_posts hook, instead that use this $query->is_post_type_archive( ‘product’ ) so the final code will be,

    function sociality_remove_product_cats_shop_page( $query ) {
    
    	// Comment out the line below to hide products in the admin as well
    	if ( is_admin() ) return;
    
    	if ( $query->is_post_type_archive( 'product' ) && $query->is_main_query() ) {
    
    		$query->set( 'tax_query', array(
    			array(
    				'taxonomy' => 'product_cat',
    				'field' => 'ID',
    				'terms' => array( 78 ),
    				'operator' => 'NOT IN'
    			)
    		) );
    
    	}
    }
    add_action( 'pre_get_posts', 'sociality_remove_product_cats_shop_page' );

    The issue is already logged here: https://github.com/woocommerce/woocommerce/issues/10625, or you can use any other solution given in that URL.

    Let us know,

    Thanks,
    laranz.

    Avatar: sociality
    sociality
    Participant
    June 19, 2017 at 13:00

    Alright,

    Thank you for the reference. I have on more concern. When I choose an option for a product with size the page loads instead of showing the pop up window for choosing weather to continue shopping or to go to cart. You can see that here http://update.dantemen.com/shop/bottoms/cut-bermuda-shorts

    Any propositions?

    Thank you.

    Avatar: sociality
    sociality
    Participant
    June 19, 2017 at 13:20

    And,

    If you could check the error in the homepage persists.

    That is all by me.

    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    June 19, 2017 at 16:13

    Hello,

    Unfortunately, variable products won’t have Ajax add to cart.
    If the problem persists only with the child theme, you need to check the customizations you’ve made in child theme files.

    Regards,
    Rose Tyler.

    Avatar: sociality
    sociality
    Participant
    June 19, 2017 at 21:12

    Ok thank you.

    Still is it possible to do something for the error in the homepage? It shows up no matter if I have the parent or the child theme enabled now.

    Thanx!

    Avatar: sociality
    sociality
    Participant
    June 20, 2017 at 00:19

    Problem solved.

    It was the same issue in a plugin.

    Thank you for the effort and contribution!

    Avatar: Rose Tyler
    Rose Tyler
    Support staff
    June 20, 2017 at 08:24

    Hello,

    You’re welcome!
    I’m glad that problem was solved.

    Regards,
    Rose Tyler.

  • Viewing 14 results - 1 through 14 (of 14 total)

You must be logged in to reply to this topic.Log in/Sign up

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.