Wednesday, 26 December 2018

Fatal error: Uncaught Error: Call to undefined function is_product()

After importing my production WordPress-associated website to my local Xampp environment, I get this error:

Fatal error: Uncaught Error: Call to undefined function is_product() in C:\xampp\htdocs\public_html\siliconharvest\wp-content\themes\storefront-child\functions.php:62 Stack trace: #0 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\class-wp-hook.php(286): wc_variable_simple_conditions('') #1 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array) #2 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\plugin.php(453): WP_Hook->do_action(Array) #3 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\general-template.php(2614): do_action('wp_head') #4 C:\xampp\htdocs\public_html\siliconharvest\wp-content\themes\storefront\header.php(18): wp_head() #5 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\template.php(688): require_once('C:\xampp\htdocs...') #6 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\template.php(647): load_template('C:\xampp\htdocs...', true) #7 C:\xampp\htdocs\public_html\siliconharvest\wp-includes\general-template.php( in C:\xampp\htdocs\public_html\siliconharvest\wp-content\themes\storefront-child\functions.php on line 62

I have attempted the following diagnostic steps, with no effect on the error:

  1. Disabled all plugins, including the plugin which concerns itself with products (Woocommerce)
  2. Re-named the storefront-child\functions.php file (to temporarily disable it)
  3. Changed the template to something other than store-front child

Yet the error persists regardless of any of the above steps. The correct solution must make all these errors go away.



from Fatal error: Uncaught Error: Call to undefined function is_product()

No comments:

Post a Comment