Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHP issues with WooCommerce integration in the Theme #35

Open
d4mation opened this issue Jun 22, 2021 · 1 comment
Open

PHP issues with WooCommerce integration in the Theme #35

d4mation opened this issue Jun 22, 2021 · 1 comment
Assignees
Labels

Comments

@d4mation
Copy link
Member

d4mation commented Jun 22, 2021

Deprecated: Function create_function() is deprecated in /srv/www/nbs/public_html/wp-content/themes/napoleonbeesupply-theme-2017/library/woocommerce.php on line 29

Notice: Trying to get property 'term_id' of non-object in /srv/www/nbs/public_html/wp-content/themes/napoleonbeesupply-theme-2017/library/woocommerce.php on line 123

The first one seems to be due to your use of create_function when setting the number of columns. A better way to do this while using an anonymous callback would be:

// Change number of columns on product pages
add_filter( 'woocommerce_product_thumbnails_columns', function( $columns ) {
    return 3; 
} );
@d4mation
Copy link
Member Author

Related to #34

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants